hgweb: open mapfile using templater.open_template()
This will help us read templates from resources in frozen binaries.
Differential Revision: https://phab.mercurial-scm.org/D8899
To run the tests, do:cd tests/python run-tests.pySee https://mercurial-scm.org/wiki/WritingTests formore information on writing tests.