public function pregReplace($str, $pattern, $replacement = '', $limit = -1)
{
return $this->handlers['text']->pregReplace($str, $pattern, $replacement, $limit);
}
public function testPregReplace() { $app = $this->getApp(); $handlers = $this->getTwigHandlers($app); $handlers['text'] = $this->getMockHandler('TextHandler', 'pregReplace'); $twig = new TwigExtension($app, $handlers, true); $twig->pregReplace(null, null, null, null); }