Added tests for generate_http_error_message for error 405 and 501.