public function countWidgets($location = null, $zone = 'frontend')
{
return $this->handlers['widget']->countWidgets($location, $zone);
}
public function testCountWidgets() { $app = $this->getApp(); $handlers = $this->getTwigHandlers($app); $handlers['widget'] = $this->getMockHandler('WidgetHandler', 'countWidgets'); $twig = new TwigExtension($app, $handlers, true); $twig->countWidgets(null, null); }