Archived
1
0

Force a attribute of the test item to be None

This commit is contained in:
Jip J. Dekker 2014-06-15 21:00:36 +02:00
parent 79cf15b95c
commit 147b148dbd

View File

@ -13,6 +13,7 @@ class TestPipelines(unittest.TestCase):
def test_none_pipeline(self):
# Testing the pipeline that replaces the None values in items.
self.testItem["value"] = "abc"
self.testItem["source"] = None
pipe = pipelines.RemoveNonePipeline()
processed = pipe.process_item(self.testItem, spider.FourmiSpider())