diff --git a/Test/ConstraintValidatorTestCase.php b/Test/ConstraintValidatorTestCase.php index f808e49ba..6584edf4d 100644 --- a/Test/ConstraintValidatorTestCase.php +++ b/Test/ConstraintValidatorTestCase.php @@ -220,8 +220,7 @@ protected function expectValidateAt(int $i, string $propertyPath, mixed $value, { $validator = $this->context->getValidator()->inContext($this->context); $validator->expectValidation($i, $propertyPath, $value, $group, function ($passedConstraints) { - $expectedConstraints = new LogicalOr(); - $expectedConstraints->setConstraints([new IsNull(), new IsIdentical([]), new IsInstanceOf(Valid::class)]); + $expectedConstraints = LogicalOr::fromConstraints(new IsNull(), new IsIdentical([]), new IsInstanceOf(Valid::class)); Assert::assertThat($passedConstraints, $expectedConstraints); });