1
0
mirror of https://github.com/scrapy/scrapy.git synced 2025-02-23 07:04:01 +00:00

fix error reporting in test: we can fail in process_request too, so result should always be defined

This commit is contained in:
Konstantin Lopuhin 2016-01-15 15:16:12 +03:00
parent 4398d95a02
commit 8330776c21

View File

@ -257,6 +257,7 @@ class RFC2616PolicyTest(DefaultStorageTest):
policy_class = 'scrapy.extensions.httpcache.RFC2616Policy'
def _process_requestresponse(self, mw, request, response):
result = None
try:
result = mw.process_request(request, self.spider)
if result: