diff --git a/src/Mixins/Expectation.php b/src/Mixins/Expectation.php index 19038bfe..56e1da09 100644 --- a/src/Mixins/Expectation.php +++ b/src/Mixins/Expectation.php @@ -969,7 +969,7 @@ private function export(mixed $value): string */ public function toBeUppercase(string $message = ''): self { - Assert::assertTrue(ctype_upper($this->value), $message); + Assert::assertTrue(ctype_upper((string) $this->value), $message); return $this; } @@ -981,7 +981,7 @@ public function toBeUppercase(string $message = ''): self */ public function toBeLowercase(string $message = ''): self { - Assert::assertTrue(ctype_lower($this->value), $message); + Assert::assertTrue(ctype_lower((string) $this->value), $message); return $this; } @@ -993,7 +993,7 @@ public function toBeLowercase(string $message = ''): self */ public function toBeAlphaNumeric(string $message = ''): self { - Assert::assertTrue(ctype_alnum($this->value), $message); + Assert::assertTrue(ctype_alnum((string) $this->value), $message); return $this; } @@ -1005,7 +1005,7 @@ public function toBeAlphaNumeric(string $message = ''): self */ public function toBeAlpha(string $message = ''): self { - Assert::assertTrue(ctype_alpha($this->value), $message); + Assert::assertTrue(ctype_alpha((string) $this->value), $message); return $this; }