Skip to content

Commit d3a219e

Browse files
authored
format code (#7654)
1 parent 3ad10f8 commit d3a219e

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

tests/Cases/ValidateAttributesTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ public function __toString(): string
125125
}
126126
}));
127127

128-
$this->assertTrue($validator->validateJson('', new class {
128+
$this->assertTrue($validator->validateJson('', new class implements Stringable {
129129
public function __toString(): string
130130
{
131131
return json_encode(['foo' => 'bar'], JSON_UNESCAPED_UNICODE);

tests/Cases/ValidationValidatorTest.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
use PHPUnit\Framework\Attributes\DataProvider;
3838
use PHPUnit\Framework\TestCase;
3939
use SplFileInfo;
40+
use Stringable;
4041

4142
/**
4243
* @internal
@@ -2856,15 +2857,15 @@ public function testValidateEmail()
28562857
$v = new Validator($trans, ['x' => ['not a string']], ['x' => 'Email']);
28572858
$this->assertFalse($v->passes());
28582859

2859-
$v = new Validator($trans, ['x' => new class {
2860+
$v = new Validator($trans, ['x' => new class implements Stringable {
28602861
public function __toString()
28612862
{
28622863
return 'aslsdlks';
28632864
}
28642865
}], ['x' => 'Email']);
28652866
$this->assertFalse($v->passes());
28662867

2867-
$v = new Validator($trans, ['x' => new class {
2868+
$v = new Validator($trans, ['x' => new class implements Stringable {
28682869
public function __toString()
28692870
{
28702871

0 commit comments

Comments
 (0)