public function testReverseLookupPath($spiUrlAliases, $prioritizedLanguageCodes, $paths, $reverseLookupLanguageCode)
{
$urlAliasService = $this->getRepository()->getURLAliasService();
$configuration = array('prioritizedLanguageList' => $prioritizedLanguageCodes, 'showAllTranslations' => false);
$this->setConfiguration($urlAliasService, $configuration);
$urlAliasHandler = $this->getPersistenceMockHandler('Content\\UrlAlias\\Handler');
$urlAliasHandler->expects($this->once())->method('listURLAliasesForLocation')->with($this->equalTo(42), $this->equalTo(false))->will($this->returnValue($spiUrlAliases));
$location = $this->getLocationStub();
$urlAlias = $urlAliasService->reverseLookup($location);
self::assertEquals(array($reverseLookupLanguageCode), $urlAlias->languageCodes);
self::assertEquals($paths[$reverseLookupLanguageCode], $urlAlias->path);
}