diff options
Diffstat (limited to 'tests/units')
-rw-r--r-- | tests/units/test_0014_big_request.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/tests/units/test_0014_big_request.py b/tests/units/test_0014_big_request.py index 2d9d861..f9428b3 100644 --- a/tests/units/test_0014_big_request.py +++ b/tests/units/test_0014_big_request.py @@ -10,10 +10,8 @@ class TestBigRequest(unittest.TestCase): self.data = 'X' * MAX_REQ_SIZE def test_post(self): - with self.assertRaises(requests.exceptions.ConnectionError) as context: - requests.post(self.url, data=self.data) - - self.assertTrue('Connection reset by peer' in str(context.exception)) + returned = requests.post(self.url, data=self.data) + self.assertEqual(returned.status_code, 413) if __name__ == '__main__': unittest.main() |