def get_request_spider_mw(self):
     crawler = get_crawler()
     spider = BaseSpider('foo')
     spider.set_crawler(crawler)
     request = Request('http://scrapytest.org/')
     return request, spider, DownloadTimeoutMiddleware.from_crawler(crawler)
Beispiel #2
0
 def get_request_spider_mw(self, settings=None):
     crawler = get_crawler(Spider, settings)
     spider = crawler._create_spider('foo')
     request = Request('http://scrapytest.org/')
     return request, spider, DownloadTimeoutMiddleware.from_crawler(crawler)
Beispiel #3
0
 def get_request_spider_mw(self):
     crawler = get_crawler()
     spider = BaseSpider('foo')
     spider.set_crawler(crawler)
     request = Request('http://scrapytest.org/')
     return request, spider, DownloadTimeoutMiddleware.from_crawler(crawler)
 def get_request_spider_mw(self):
     crawler = get_crawler()
     spider = Spider("foo")
     spider.set_crawler(crawler)
     request = Request("http://scrapytest.org/")
     return request, spider, DownloadTimeoutMiddleware.from_crawler(crawler)