Skip to content

Commit 3b63b2e

Browse files
committed
Merge pull request #1950 from XWB/testfix
Fixed form tests for Symfony 2.3
2 parents 507a71f + 76f85db commit 3b63b2e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Tests/Form/Type/ValidatorExtensionTypeTestCase.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,12 @@ class ValidatorExtensionTypeTestCase extends TypeTestCase
1515
{
1616
protected function getTypeExtensions()
1717
{
18-
$validator = $this->getMock('Symfony\Component\Validator\Validator\ValidatorInterface');
18+
if (interface_exists('Symfony\Component\Validator\Validator\ValidatorInterface')) {
19+
$validator = $this->getMock('Symfony\Component\Validator\Validator\ValidatorInterface');
20+
} else {
21+
$validator = $this->getMock('Symfony\Component\Validator\ValidatorInterface');
22+
}
23+
1924
$validator->method('validate')->will($this->returnValue(new ConstraintViolationList()));
2025

2126
return array(

0 commit comments

Comments
 (0)