File tree 2 files changed +3
-3
lines changed
src/Symfony/Component/Form
Tests/Extension/Validator/Type 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ public function __construct(ValidatorInterface $validator)
36
36
// code must be kept synchronized with validation.xml
37
37
38
38
/** @var \Symfony\Component\Validator\Mapping\ClassMetadata $metadata */
39
- $ metadata = $ this ->validator ->getMetadataFactory ()->getClassMetadata ('Symfony\Component\Form\Form ' );
39
+ $ metadata = $ this ->validator ->getMetadataFactory ()->getMetadataFor ('Symfony\Component\Form\Form ' );
40
40
$ metadata ->addConstraint (new Form ());
41
41
$ metadata ->addPropertyConstraint ('children ' , new Valid ());
42
42
}
Original file line number Diff line number Diff line change @@ -25,10 +25,10 @@ protected function setUp()
25
25
}
26
26
27
27
$ this ->validator = $ this ->getMock ('Symfony\Component\Validator\ValidatorInterface ' );
28
- $ metadataFactory = $ this ->getMock ('Symfony\Component\Validator\Mapping\ClassMetadataFactoryInterface ' );
28
+ $ metadataFactory = $ this ->getMock ('Symfony\Component\Validator\MetadataFactoryInterface ' );
29
29
$ this ->validator ->expects ($ this ->once ())->method ('getMetadataFactory ' )->will ($ this ->returnValue ($ metadataFactory ));
30
30
$ metadata = $ this ->getMockBuilder ('Symfony\Component\Validator\Mapping\ClassMetadata ' )->disableOriginalConstructor ()->getMock ();
31
- $ metadataFactory ->expects ($ this ->once ())->method ('getClassMetadata ' )->will ($ this ->returnValue ($ metadata ));
31
+ $ metadataFactory ->expects ($ this ->once ())->method ('getMetadataFor ' )->will ($ this ->returnValue ($ metadata ));
32
32
33
33
parent ::setUp ();
34
34
}
You can’t perform that action at this time.
0 commit comments