(self)
| 261 | self.assertBody('Hello world!') |
| 262 | |
| 263 | def test_malformed_header(self): |
| 264 | c = self.make_connection() |
| 265 | c.putrequest('GET', '/') |
| 266 | c.putheader('Content-Type', 'text/plain') |
| 267 | # See https://github.com/cherrypy/cherrypy/issues/941 |
| 268 | c._output(b're, 1.2.3.4#015#012') |
| 269 | c.endheaders() |
| 270 | |
| 271 | response = c.getresponse() |
| 272 | self.status = str(response.status) |
| 273 | self.assertStatus(400) |
| 274 | self.body = response.fp.read(20) |
| 275 | self.assertBody('Illegal header line.') |
| 276 | |
| 277 | response.close() |
| 278 | c.close() |
| 279 | |
| 280 | def test_http_over_https(self): |
| 281 | if self.scheme != 'https': |
nothing calls this directly
no test coverage detected