public function testLoadByRemoteId()
{
$gatewayMock = $this->getGatewayMock();
$gatewayMock->expects($this->once())->method('loadTypeDataByRemoteId')->with($this->equalTo('someLongHash'), $this->equalTo(0))->will($this->returnValue(array()));
$mapperMock = $this->getMapperMock();
$mapperMock->expects($this->once())->method('extractTypesFromRows')->will($this->returnValue(array(new Type())));
$handler = $this->getHandler();
$type = $handler->loadByRemoteId('someLongHash');
$this->assertEquals(new Type(), $type, 'Type not loaded correctly');
}