custom error message and tests for HTTP redirection