(self)
| 180 | self.assertEqual(err.splitlines()[-2], exc_message) |
| 181 | |
| 182 | def test_wsgi_input(self): |
| 183 | def bad_app(e,s): |
| 184 | e["wsgi.input"].read() |
| 185 | s("200 OK", [("Content-Type", "text/plain; charset=utf-8")]) |
| 186 | return [b"data"] |
| 187 | out, err = run_amock(validator(bad_app)) |
| 188 | self.assertEndsWith(out, |
| 189 | b"A server error occurred. Please contact the administrator." |
| 190 | ) |
| 191 | self.assertEqual( |
| 192 | err.splitlines()[-2], "AssertionError" |
| 193 | ) |
| 194 | |
| 195 | def test_bytes_validation(self): |
| 196 | def app(e, s): |
nothing calls this directly
no test coverage detected