Also make config-related code more generic and improve unit tests of config parsing.
TODO: Still need to test "HTML_FILE". Response to HTTP request.