protected function ChoiceValidatorTest::setUp

File

drupal/core/vendor/symfony/validator/Symfony/Component/Validator/Tests/Constraints/ChoiceValidatorTest.php, line 32

Class

ChoiceValidatorTest

Namespace

Symfony\Component\Validator\Tests\Constraints

Code

protected function setUp() {
  $this->context = $this
    ->getMock('Symfony\\Component\\Validator\\ExecutionContext', array(), array(), '', false);
  $this->validator = new ChoiceValidator();
  $this->validator
    ->initialize($this->context);
  $this->context
    ->expects($this
    ->any())
    ->method('getClassName')
    ->will($this
    ->returnValue(__CLASS__));
}