/** * @depends testConstruct */ public function testSetMatcherBuilder(Compound $compoundMatcher) { $this->matcherBuilder->expects($this->any())->method('buildMatcher')->will($this->returnValue($this->getMock('eZ\\Publish\\Core\\MVC\\Symfony\\SiteAccess\\Matcher'))); $compoundMatcher->setRequest($this->getMock('eZ\\Publish\\Core\\MVC\\Symfony\\Routing\\SimplifiedRequest')); $compoundMatcher->setMatcherBuilder($this->matcherBuilder); $matchers = $compoundMatcher->getSubMatchers(); $this->assertInternalType('array', $matchers); foreach ($matchers as $matcher) { $this->assertInstanceOf('eZ\\Publish\\Core\\MVC\\Symfony\\SiteAccess\\Matcher', $matcher); } }