From 4013e7b9984eeabc0704853dc1df94066ef17442 Mon Sep 17 00:00:00 2001 From: Pierre du Plessis Date: Mon, 6 Mar 2017 09:20:15 +0200 Subject: [PATCH] Add validate method to mockec validator in form TypeTestCase --- .../Form/Tests/Extension/Validator/Type/TypeTestCase.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Symfony/Component/Form/Tests/Extension/Validator/Type/TypeTestCase.php b/src/Symfony/Component/Form/Tests/Extension/Validator/Type/TypeTestCase.php index 663cdd0339..cb6000aa8f 100644 --- a/src/Symfony/Component/Form/Tests/Extension/Validator/Type/TypeTestCase.php +++ b/src/Symfony/Component/Form/Tests/Extension/Validator/Type/TypeTestCase.php @@ -23,6 +23,7 @@ abstract class TypeTestCase extends BaseTypeTestCase $this->validator = $this->getMockBuilder('Symfony\Component\Validator\Validator\ValidatorInterface')->getMock(); $metadata = $this->getMockBuilder('Symfony\Component\Validator\Mapping\ClassMetadata')->disableOriginalConstructor()->getMock(); $this->validator->expects($this->once())->method('getMetadataFor')->will($this->returnValue($metadata)); + $this->validator->expects($this->any())->method('validate')->will($this->returnValue(array())); parent::setUp(); }