feat #1132 Add test for env. parameter for escapeforhtml

Made a few changes to the feature implementation, one for code consistency and one for fixing a discrepancy in identifiers use.

The new use case has been tested:

- a template gets compiled with the parameter turned off
- a classical use case is run and checked regarding that
- the parameter is reverted

This required to have two tests, to be able to have two different template compilations. Therefore a bit of refactoring has been done too.