public function it_should_resolve_template_name_from_collection_type_route_and_defaultArticlesTemplate_set_and_defaultTemplate_in_article_(Route $route, ArticleInterface $article) { $route->getType()->willReturn(RouteInterface::TYPE_COLLECTION); $route->getTemplateName()->willReturn('test2.html.twig'); $route->getArticlesTemplateName()->willReturn('article_template.html.twig'); $article->getRoute()->willReturn($route); $article->getTemplateName()->willReturn('custom_article.html.twig'); $this->resolve($article)->shouldReturn('custom_article.html.twig'); }