Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2eed84b

Browse filesBrowse files
[Validator] Improve return types in tests
1 parent 36e240c commit 2eed84b
Copy full SHA for 2eed84b

File tree

58 files changed

+66
-113
lines changed
Filter options

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Dismiss banner

58 files changed

+66
-113
lines changed

‎src/Symfony/Component/Form/Tests/Extension/Validator/Constraints/FormValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Form/Tests/Extension/Validator/Constraints/FormValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
use Symfony\Component\Validator\Constraints\NotBlank;
3131
use Symfony\Component\Validator\Constraints\NotNull;
3232
use Symfony\Component\Validator\Constraints\Valid;
33-
use Symfony\Component\Validator\ConstraintValidatorInterface;
3433
use Symfony\Component\Validator\Context\ExecutionContext;
3534
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
3635
use Symfony\Component\Validator\Validation;
@@ -715,7 +714,7 @@ public function testCauseForNotAllowedExtraFieldsIsTheFormConstraint()
715714
$this->assertSame($constraint, $context->getViolations()->get(0)->getConstraint());
716715
}
717716

718-
protected function createValidator(): ConstraintValidatorInterface
717+
protected function createValidator(): FormValidator
719718
{
720719
return new FormValidator();
721720
}

‎src/Symfony/Component/Security/Core/Tests/Validator/Constraints/UserPasswordValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Security/Core/Tests/Validator/Constraints/UserPasswordValidatorTest.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ abstract class UserPasswordValidatorTest extends ConstraintValidatorTestCase
4545
*/
4646
protected $hasherFactory;
4747

48-
protected function createValidator(): ConstraintValidatorInterface
48+
protected function createValidator(): UserPasswordValidator
4949
{
5050
return new UserPasswordValidator($this->tokenStorage, $this->hasherFactory);
5151
}

‎src/Symfony/Component/Validator/Tests/Constraints/AllValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/AllValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,12 @@
1515
use Symfony\Component\Validator\Constraints\AllValidator;
1616
use Symfony\Component\Validator\Constraints\NotNull;
1717
use Symfony\Component\Validator\Constraints\Range;
18-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1918
use Symfony\Component\Validator\Exception\UnexpectedValueException;
2019
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2120

2221
class AllValidatorTest extends ConstraintValidatorTestCase
2322
{
24-
protected function createValidator(): ConstraintValidatorInterface
23+
protected function createValidator(): AllValidator
2524
{
2625
return new AllValidator();
2726
}

‎src/Symfony/Component/Validator/Tests/Constraints/AtLeastOneOfValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/AtLeastOneOfValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
use Symfony\Component\Validator\Constraints\Regex;
3232
use Symfony\Component\Validator\Constraints\Unique;
3333
use Symfony\Component\Validator\Constraints\Valid;
34-
use Symfony\Component\Validator\ConstraintValidatorInterface;
3534
use Symfony\Component\Validator\ConstraintViolation;
3635
use Symfony\Component\Validator\Mapping\ClassMetadata;
3736
use Symfony\Component\Validator\Mapping\Factory\MetadataFactoryInterface;
@@ -44,7 +43,7 @@
4443
*/
4544
class AtLeastOneOfValidatorTest extends ConstraintValidatorTestCase
4645
{
47-
protected function createValidator(): ConstraintValidatorInterface
46+
protected function createValidator(): AtLeastOneOfValidator
4847
{
4948
return new AtLeastOneOfValidator();
5049
}

‎src/Symfony/Component/Validator/Tests/Constraints/BicValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/BicValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Symfony\Component\Validator\Constraints\Bic;
1515
use Symfony\Component\Validator\Constraints\BicValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Exception\ConstraintDefinitionException;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Mapping\ClassMetadata;
@@ -22,7 +21,7 @@
2221

2322
class BicValidatorTest extends ConstraintValidatorTestCase
2423
{
25-
protected function createValidator(): ConstraintValidatorInterface
24+
protected function createValidator(): BicValidator
2625
{
2726
return new BicValidator();
2827
}

‎src/Symfony/Component/Validator/Tests/Constraints/BlankValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/BlankValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,11 @@
1313

1414
use Symfony\Component\Validator\Constraints\Blank;
1515
use Symfony\Component\Validator\Constraints\BlankValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1817

1918
class BlankValidatorTest extends ConstraintValidatorTestCase
2019
{
21-
protected function createValidator(): ConstraintValidatorInterface
20+
protected function createValidator(): BlankValidator
2221
{
2322
return new BlankValidator();
2423
}

‎src/Symfony/Component/Validator/Tests/Constraints/CallbackValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CallbackValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\Validator\Constraint;
1515
use Symfony\Component\Validator\Constraints\Callback;
1616
use Symfony\Component\Validator\Constraints\CallbackValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Context\ExecutionContextInterface;
1918
use Symfony\Component\Validator\Exception\ConstraintDefinitionException;
2019
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
@@ -48,7 +47,7 @@ public static function validateStatic($object, ExecutionContextInterface $contex
4847

4948
class CallbackValidatorTest extends ConstraintValidatorTestCase
5049
{
51-
protected function createValidator(): ConstraintValidatorInterface
50+
protected function createValidator(): CallbackValidator
5251
{
5352
return new CallbackValidator();
5453
}

‎src/Symfony/Component/Validator/Tests/Constraints/CardSchemeValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CardSchemeValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,11 @@
1313

1414
use Symfony\Component\Validator\Constraints\CardScheme;
1515
use Symfony\Component\Validator\Constraints\CardSchemeValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1817

1918
class CardSchemeValidatorTest extends ConstraintValidatorTestCase
2019
{
21-
protected function createValidator(): ConstraintValidatorInterface
20+
protected function createValidator(): CardSchemeValidator
2221
{
2322
return new CardSchemeValidator();
2423
}

‎src/Symfony/Component/Validator/Tests/Constraints/ChoiceValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/ChoiceValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Symfony\Component\Validator\Constraints\Choice;
1515
use Symfony\Component\Validator\Constraints\ChoiceValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Exception\ConstraintDefinitionException;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
@@ -25,7 +24,7 @@ function choice_callback()
2524

2625
class ChoiceValidatorTest extends ConstraintValidatorTestCase
2726
{
28-
protected function createValidator(): ConstraintValidatorInterface
27+
protected function createValidator(): ChoiceValidator
2928
{
3029
return new ChoiceValidator();
3130
}

‎src/Symfony/Component/Validator/Tests/Constraints/CollectionValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CollectionValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,12 @@
1717
use Symfony\Component\Validator\Constraints\Optional;
1818
use Symfony\Component\Validator\Constraints\Range;
1919
use Symfony\Component\Validator\Constraints\Required;
20-
use Symfony\Component\Validator\ConstraintValidatorInterface;
2120
use Symfony\Component\Validator\Exception\UnexpectedValueException;
2221
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2322

2423
abstract class CollectionValidatorTest extends ConstraintValidatorTestCase
2524
{
26-
protected function createValidator(): ConstraintValidatorInterface
25+
protected function createValidator(): CollectionValidator
2726
{
2827
return new CollectionValidator();
2928
}

‎src/Symfony/Component/Validator/Tests/Constraints/CompoundValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CompoundValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,11 @@
1515
use Symfony\Component\Validator\Constraints\CompoundValidator;
1616
use Symfony\Component\Validator\Constraints\Length;
1717
use Symfony\Component\Validator\Constraints\NotBlank;
18-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2019

2120
class CompoundValidatorTest extends ConstraintValidatorTestCase
2221
{
23-
protected function createValidator(): ConstraintValidatorInterface
22+
protected function createValidator(): CompoundValidator
2423
{
2524
return new CompoundValidator();
2625
}

‎src/Symfony/Component/Validator/Tests/Constraints/CountValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CountValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\Validator\Constraints\Count;
1515
use Symfony\Component\Validator\Constraints\CountValidator;
1616
use Symfony\Component\Validator\Constraints\DivisibleBy;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2019

@@ -23,7 +22,7 @@
2322
*/
2423
abstract class CountValidatorTest extends ConstraintValidatorTestCase
2524
{
26-
protected function createValidator(): ConstraintValidatorInterface
25+
protected function createValidator(): CountValidator
2726
{
2827
return new CountValidator();
2928
}

‎src/Symfony/Component/Validator/Tests/Constraints/CountryValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CountryValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\Intl\Util\IntlTestHelper;
1515
use Symfony\Component\Validator\Constraints\Country;
1616
use Symfony\Component\Validator\Constraints\CountryValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2019

@@ -36,7 +35,7 @@ protected function tearDown(): void
3635
\Locale::setDefault($this->defaultLocale);
3736
}
3837

39-
protected function createValidator(): ConstraintValidatorInterface
38+
protected function createValidator(): CountryValidator
4039
{
4140
return new CountryValidator();
4241
}

‎src/Symfony/Component/Validator/Tests/Constraints/CurrencyValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/CurrencyValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\Intl\Util\IntlTestHelper;
1515
use Symfony\Component\Validator\Constraints\Currency;
1616
use Symfony\Component\Validator\Constraints\CurrencyValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2019

@@ -36,7 +35,7 @@ protected function tearDown(): void
3635
\Locale::setDefault($this->defaultLocale);
3736
}
3837

39-
protected function createValidator(): ConstraintValidatorInterface
38+
protected function createValidator(): CurrencyValidator
4039
{
4140
return new CurrencyValidator();
4241
}

‎src/Symfony/Component/Validator/Tests/Constraints/DateTimeValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/DateTimeValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,12 @@
1313

1414
use Symfony\Component\Validator\Constraints\DateTime;
1515
use Symfony\Component\Validator\Constraints\DateTimeValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1817
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1918

2019
class DateTimeValidatorTest extends ConstraintValidatorTestCase
2120
{
22-
protected function createValidator(): ConstraintValidatorInterface
21+
protected function createValidator(): DateTimeValidator
2322
{
2423
return new DateTimeValidator();
2524
}

‎src/Symfony/Component/Validator/Tests/Constraints/DateValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/DateValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,12 @@
1313

1414
use Symfony\Component\Validator\Constraints\Date;
1515
use Symfony\Component\Validator\Constraints\DateValidator;
16-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1716
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1817
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1918

2019
class DateValidatorTest extends ConstraintValidatorTestCase
2120
{
22-
protected function createValidator(): ConstraintValidatorInterface
21+
protected function createValidator(): DateValidator
2322
{
2423
return new DateValidator();
2524
}

‎src/Symfony/Component/Validator/Tests/Constraints/DivisibleByValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/DivisibleByValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,14 @@
1414
use Symfony\Component\Validator\Constraint;
1515
use Symfony\Component\Validator\Constraints\DivisibleBy;
1616
use Symfony\Component\Validator\Constraints\DivisibleByValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918

2019
/**
2120
* @author Colin O'Dell <colinodell@gmail.com>
2221
*/
2322
class DivisibleByValidatorTest extends AbstractComparisonValidatorTestCase
2423
{
25-
protected function createValidator(): ConstraintValidatorInterface
24+
protected function createValidator(): DivisibleByValidator
2625
{
2726
return new DivisibleByValidator();
2827
}

‎src/Symfony/Component/Validator/Tests/Constraints/EmailValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/EmailValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Bridge\PhpUnit\ExpectDeprecationTrait;
1515
use Symfony\Component\Validator\Constraints\Email;
1616
use Symfony\Component\Validator\Constraints\EmailValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\UnexpectedValueException;
1918
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
2019

@@ -25,7 +24,7 @@ class EmailValidatorTest extends ConstraintValidatorTestCase
2524
{
2625
use ExpectDeprecationTrait;
2726

28-
protected function createValidator(): ConstraintValidatorInterface
27+
protected function createValidator(): EmailValidator
2928
{
3029
return new EmailValidator(Email::VALIDATION_MODE_HTML5);
3130
}

‎src/Symfony/Component/Validator/Tests/Constraints/EqualToValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/EqualToValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,13 @@
1414
use Symfony\Component\Validator\Constraint;
1515
use Symfony\Component\Validator\Constraints\EqualTo;
1616
use Symfony\Component\Validator\Constraints\EqualToValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817

1918
/**
2019
* @author Daniel Holmes <daniel@danielholmes.org>
2120
*/
2221
class EqualToValidatorTest extends AbstractComparisonValidatorTestCase
2322
{
24-
protected function createValidator(): ConstraintValidatorInterface
23+
protected function createValidator(): EqualToValidator
2524
{
2625
return new EqualToValidator();
2726
}

‎src/Symfony/Component/Validator/Tests/Constraints/ExpressionLanguageSyntaxValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/ExpressionLanguageSyntaxValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,14 @@
1414
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
1515
use Symfony\Component\Validator\Constraints\ExpressionLanguageSyntax;
1616
use Symfony\Component\Validator\Constraints\ExpressionLanguageSyntaxValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1918

2019
/**
2120
* @group legacy
2221
*/
2322
class ExpressionLanguageSyntaxValidatorTest extends ConstraintValidatorTestCase
2423
{
25-
protected function createValidator(): ConstraintValidatorInterface
24+
protected function createValidator(): ExpressionLanguageSyntaxValidator
2625
{
2726
return new ExpressionLanguageSyntaxValidator(new ExpressionLanguage());
2827
}

‎src/Symfony/Component/Validator/Tests/Constraints/ExpressionSyntaxValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/ExpressionSyntaxValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,11 @@
1414
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
1515
use Symfony\Component\Validator\Constraints\ExpressionSyntax;
1616
use Symfony\Component\Validator\Constraints\ExpressionSyntaxValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1918

2019
class ExpressionSyntaxValidatorTest extends ConstraintValidatorTestCase
2120
{
22-
protected function createValidator(): ConstraintValidatorInterface
21+
protected function createValidator(): ExpressionSyntaxValidator
2322
{
2423
return new ExpressionSyntaxValidator(new ExpressionLanguage());
2524
}

‎src/Symfony/Component/Validator/Tests/Constraints/ExpressionValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/ExpressionValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,13 @@
1414
use Symfony\Component\ExpressionLanguage\ExpressionLanguage;
1515
use Symfony\Component\Validator\Constraints\Expression;
1616
use Symfony\Component\Validator\Constraints\ExpressionValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
1918
use Symfony\Component\Validator\Tests\Fixtures\Annotation\Entity;
2019
use Symfony\Component\Validator\Tests\Fixtures\ToString;
2120

2221
class ExpressionValidatorTest extends ConstraintValidatorTestCase
2322
{
24-
protected function createValidator(): ConstraintValidatorInterface
23+
protected function createValidator(): ExpressionValidator
2524
{
2625
return new ExpressionValidator();
2726
}

‎src/Symfony/Component/Validator/Tests/Constraints/FileValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/FileValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
use Symfony\Component\HttpFoundation\File\UploadedFile;
1515
use Symfony\Component\Validator\Constraints\File;
1616
use Symfony\Component\Validator\Constraints\FileValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817
use Symfony\Component\Validator\Exception\ConstraintDefinitionException;
1918
use Symfony\Component\Validator\Exception\UnexpectedValueException;
2019
use Symfony\Component\Validator\Test\ConstraintValidatorTestCase;
@@ -25,7 +24,7 @@ abstract class FileValidatorTest extends ConstraintValidatorTestCase
2524

2625
protected $file;
2726

28-
protected function createValidator(): ConstraintValidatorInterface
27+
protected function createValidator(): FileValidator
2928
{
3029
return new FileValidator();
3130
}

‎src/Symfony/Component/Validator/Tests/Constraints/Fixtures/WhenTestWithAttributes.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/Fixtures/WhenTestWithAttributes.php
+9Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
11
<?php
22

3+
/*
4+
* This file is part of the Symfony package.
5+
*
6+
* (c) Fabien Potencier <fabien@symfony.com>
7+
*
8+
* For the full copyright and license information, please view the LICENSE
9+
* file that was distributed with this source code.
10+
*/
11+
312
namespace Symfony\Component\Validator\Tests\Constraints\Fixtures;
413

514
use Symfony\Component\Validator\Constraints\Callback;

‎src/Symfony/Component/Validator/Tests/Constraints/GreaterThanOrEqualValidatorTest.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Tests/Constraints/GreaterThanOrEqualValidatorTest.php
+1-2Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,13 @@
1414
use Symfony\Component\Validator\Constraint;
1515
use Symfony\Component\Validator\Constraints\GreaterThanOrEqual;
1616
use Symfony\Component\Validator\Constraints\GreaterThanOrEqualValidator;
17-
use Symfony\Component\Validator\ConstraintValidatorInterface;
1817

1918
/**
2019
* @author Daniel Holmes <daniel@danielholmes.org>
2120
*/
2221
class GreaterThanOrEqualValidatorTest extends AbstractComparisonValidatorTestCase
2322
{
24-
protected function createValidator(): ConstraintValidatorInterface
23+
protected function createValidator(): GreaterThanOrEqualValidator
2524
{
2625
return new GreaterThanOrEqualValidator();
2726
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.