public function testApplySingleVersionSingleTranslation()
{
$contentId = 42;
$versionNumbers = array(1);
$content = $this->getContentFixture(1, array('cro-HR'));
$action = $this->getMockedAction(array('insertField'));
$this->getContentGatewayMock()->expects($this->once())->method('listVersionNumbers')->with($this->equalTo($contentId))->will($this->returnValue($versionNumbers));
$this->getContentGatewayMock()->expects($this->once())->method('loadVersionedNameData')->with($this->equalTo(array(array('id' => $contentId, 'version' => 1))))->will($this->returnValue(array()));
$this->getContentGatewayMock()->expects($this->at(2))->method('load')->with($contentId, 1)->will($this->returnValue(array()));
$this->getContentMapperMock()->expects($this->once())->method('extractContentFromRows')->with(array(), array())->will($this->returnValue(array($content)));
$action->expects($this->once())->method('insertField')->with($content, $this->getFieldReference(null, 1, 'cro-HR'))->will($this->returnValue('fieldId1'));
$action->apply($contentId);
}