Fix: Fatal Error on adding tests and filters

Addition to the addFunction (https://github.com/fabpot/Twig/pull/1042), fix for addTest and addFilter