mirror of https://github.com/scrapy/scrapy.git
Fix tests
This commit is contained in:
parent
701f582f27
commit
7b89aeba0b
|
|
@ -180,7 +180,8 @@ class ExecutionEngine:
|
|||
self._start = None
|
||||
exception_traceback = format_exc()
|
||||
logger.error(
|
||||
f"Error while reading start items and requests: {exception}.\n{exception_traceback}"
|
||||
f"Error while reading start items and requests: {exception}.\n{exception_traceback}",
|
||||
exc_info=True,
|
||||
)
|
||||
else:
|
||||
if isinstance(item_or_request, Request):
|
||||
|
|
|
|||
|
|
@ -456,13 +456,8 @@ class TestCrawlSpider(TestSpider):
|
|||
crawler = get_crawler(TestSpider)
|
||||
with LogCapture("scrapy.core.engine", propagate=False, level=ERROR) as log:
|
||||
yield crawler.crawl()
|
||||
log.check(
|
||||
(
|
||||
"scrapy.core.engine",
|
||||
"ERROR",
|
||||
"Error while reading start items and requests",
|
||||
),
|
||||
)
|
||||
assert "Error while reading start items and requests" in str(log)
|
||||
assert "did you miss an 's'?" in str(log)
|
||||
|
||||
|
||||
class TestSitemapSpider(TestSpider):
|
||||
|
|
|
|||
Loading…
Reference in New Issue