function it_uses_custom_template_if_specified(\Twig_Environment $twig, GridView $gridView) { $twig->render('SyliusGridBundle:custom.html.twig', ['grid' => $gridView])->willReturn('<html>Grid!</html>'); $this->render($gridView, 'SyliusGridBundle:custom.html.twig')->shouldReturn('<html>Grid!</html>'); }