eZ\Publish\Core\Persistence\Legacy\Tests\Content\Type\ContentTypeHandlerTest::testLoad PHP Method

testLoad() public method

public testLoad ( )
    public function testLoad()
    {
        $gatewayMock = $this->getGatewayMock();
        $gatewayMock->expects($this->once())->method('loadTypeData')->with($this->equalTo(23), $this->equalTo(1))->will($this->returnValue(array()));
        $mapperMock = $this->getMapperMock();
        $mapperMock->expects($this->once())->method('extractTypesFromRows')->with($this->equalTo(array()))->will($this->returnValue(array(new Type())));
        $handler = $this->getHandler();
        $type = $handler->load(23, 1);
        $this->assertEquals(new Type(), $type, 'Type not loaded correctly');
    }