/**
* @dataProvider reverseMatchProvider
*/
public function testReverseMatch($siteAccessName, $originalPathinfo)
{
$matcher = new URIElementMatcher(1);
$matcher->setRequest(new SimplifiedRequest(array('pathinfo' => $originalPathinfo)));
$result = $matcher->reverseMatch($siteAccessName);
$this->assertInstanceOf('eZ\\Publish\\Core\\MVC\\Symfony\\SiteAccess\\Matcher\\URIElement', $result);
$this->assertSame("/{$siteAccessName}{$originalPathinfo}", $result->getRequest()->pathinfo);
$this->assertSame("/{$siteAccessName}/some/linked/uri", $result->analyseLink('/some/linked/uri'));
$this->assertSame('/foo/bar/baz', $result->analyseURI("/{$siteAccessName}/foo/bar/baz"));
}