'If the response body doesn\'t match the provided schema, then the
request automatically receives a I{INTERNAL SERVER ERROR} response.
This test fails if ``_validate_responses == False``.  Hence it also
confirms that validation is enabled for other tests.'

@validateLogging(_assertTracebackLogged(ValidationError))
def test_responseValidationError(self, logger):

    request = dummyRequest('GET', '/foo/badresponse', Headers({'content-type': ['application/json']}), '')
    app = self.Application(logger, None)
    render(app.app.resource(), request)
    self.assertEqual(request._code, INTERNAL_SERVER_ERROR)
