Skip to content

Commit d5f4afb

Browse files
Merge branch '4.3' into 4.4
* 4.3: [HttpFoundation] Throw exception when the \"session\" extension is not loaded remove invalid test case remove invalid test cases [Serializer] Fixed PHP of DenormalizableInterface::denormalize [Cache] work aroung PHP memory leak [Finder] docblock fixes pass error code as a string Catch JsonException and rethrow in JsonEncode
2 parents 2212301 + d44c72e commit d5f4afb

File tree

3 files changed

+2
-27
lines changed

3 files changed

+2
-27
lines changed

Tests/Constraints/AbstractComparisonValidatorTestCase.php

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -148,20 +148,6 @@ public function testValidComparisonToPropertyPath($comparedValue)
148148
$this->assertNoViolation();
149149
}
150150

151-
/**
152-
* @dataProvider provideValidComparisonsToPropertyPath
153-
*/
154-
public function testValidComparisonToPropertyPathOnArray($comparedValue)
155-
{
156-
$constraint = $this->createConstraint(['propertyPath' => '[root][value]']);
157-
158-
$this->setObject(['root' => ['value' => 5]]);
159-
160-
$this->validator->validate($comparedValue, $constraint);
161-
162-
$this->assertNoViolation();
163-
}
164-
165151
public function testNoViolationOnNullObjectWithPropertyPath()
166152
{
167153
$constraint = $this->createConstraint(['propertyPath' => 'propertyPath']);

Tests/Constraints/BicValidatorTest.php

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,6 @@ public function testValidComparisonToPropertyPath()
5050
$this->assertNoViolation();
5151
}
5252

53-
public function testValidComparisonToPropertyPathOnArray()
54-
{
55-
$constraint = new Bic(['ibanPropertyPath' => '[root][value]']);
56-
57-
$this->setObject(['root' => ['value' => 'FR14 2004 1010 0505 0001 3M02 606']]);
58-
59-
$this->validator->validate('SOGEFRPP', $constraint);
60-
61-
$this->assertNoViolation();
62-
}
63-
6453
public function testInvalidComparisonToPropertyPath()
6554
{
6655
$constraint = new Bic(['ibanPropertyPath' => 'value']);

Tests/Validator/AbstractTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -511,7 +511,7 @@ public function testAddCustomizedViolation()
511511
->setParameter('%param%', 'value')
512512
->setInvalidValue('Invalid value')
513513
->setPlural(2)
514-
->setCode(42)
514+
->setCode('42')
515515
->addViolation();
516516
};
517517

@@ -528,7 +528,7 @@ public function testAddCustomizedViolation()
528528
$this->assertSame($entity, $violations[0]->getRoot());
529529
$this->assertSame('Invalid value', $violations[0]->getInvalidValue());
530530
$this->assertSame(2, $violations[0]->getPlural());
531-
$this->assertSame(42, $violations[0]->getCode());
531+
$this->assertSame('42', $violations[0]->getCode());
532532
}
533533

534534
public function testNoDuplicateValidationIfClassConstraintInMultipleGroups()

0 commit comments

Comments
 (0)