From 8e38f70a746de67cb3afcc6240c7c6a0521bb383 Mon Sep 17 00:00:00 2001 From: samus_ Date: Fri, 9 Jan 2009 01:33:12 +0000 Subject: [PATCH] small improvement to Response.__init__ testcase --HG-- extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%40692 --- scrapy/trunk/scrapy/tests/test_http_response.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scrapy/trunk/scrapy/tests/test_http_response.py b/scrapy/trunk/scrapy/tests/test_http_response.py index 71e87b8b7..2d7d0641f 100644 --- a/scrapy/trunk/scrapy/tests/test_http_response.py +++ b/scrapy/trunk/scrapy/tests/test_http_response.py @@ -11,6 +11,8 @@ class ResponseTest(TestCase): self.assertTrue(isinstance(Response('example.com', 'http://example.com/', body=None), Response)) self.assertTrue(isinstance(Response('example.com', 'http://example.com/', body='body'), Response)) self.assertRaises(AssertionError, Response, 'example.com', 'http://example.com/', body=ResponseBody('body', 'utf-8')) + # test presence of all optional parameters + self.assertTrue(isinstance(Response('example.com', 'http://example.com/', original_url='http://example.com/None', headers={}, status=200, body=None), Response)) class ResponseBodyTest(TestCase): unicode_string = u'\u043a\u0438\u0440\u0438\u043b\u043b\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0442\u0435\u043a\u0441\u0442'