Symfony\Component\Form\Tests\Extension\Validator\ValidatorTypeGuesserTest::setUp PHP Method

setUp() protected method

protected setUp ( )
    protected function setUp()
    {
        $this->metadata = new ClassMetadata(self::TEST_CLASS);
        $this->metadataFactory = $this->getMockBuilder('Symfony\Component\Validator\Mapping\Factory\MetadataFactoryInterface')->getMock();
        $this->metadataFactory->expects($this->any())
            ->method('getMetadataFor')
            ->with(self::TEST_CLASS)
            ->will($this->returnValue($this->metadata));
        $this->guesser = new ValidatorTypeGuesser($this->metadataFactory);
    }