(self, m_http)
| 528 | |
| 529 | @unittest.mock.patch('aiohttp.client_reqrep.aiohttp') |
| 530 | def test_content_encoding(self, m_http): |
| 531 | req = ClientRequest('get', 'http://python.org/', |
| 532 | compress='deflate', loop=self.loop) |
| 533 | resp = req.send(self.transport, self.protocol) |
| 534 | self.assertEqual(req.headers['TRANSFER-ENCODING'], 'chunked') |
| 535 | self.assertEqual(req.headers['CONTENT-ENCODING'], 'deflate') |
| 536 | m_http.Request.return_value\ |
| 537 | .add_compression_filter.assert_called_with('deflate') |
| 538 | self.loop.run_until_complete(req.close()) |
| 539 | resp.close() |
| 540 | |
| 541 | @unittest.mock.patch('aiohttp.client_reqrep.aiohttp') |
| 542 | def test_content_encoding_header(self, m_http): |
nothing calls this directly
no test coverage detected