Added missing unit tests and refactored view provider to allow setting twig options.