Conditions | 1 |
Paths | 1 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
17 | public function testCombinesMultipleConstraintAndPassesWhenAllAreFulfilled() : void |
||
18 | { |
||
19 | $constraint = new CompositeConstraint( |
||
20 | new TypeConstraint(TestNullableType::fromType(new StringType())), |
||
21 | new RequiredConstraint() |
||
22 | ); |
||
23 | |||
24 | $constraint->validate('foo'); |
||
25 | |||
26 | $this->expectException(ConstraintNotFulfilled::class); |
||
27 | |||
28 | $constraint->validate(null); |
||
29 | } |
||
31 |