first draft of enhancers.
This commit is contained in:
@ -12,7 +12,7 @@ def test_write_csv_to_file(tmpdir):
|
||||
writer = CsvWriter(path=filename)
|
||||
context = NodeExecutionContext(writer, services={'fs': fs})
|
||||
|
||||
context.recv(BEGIN, Bag({'foo': 'bar'}), Bag({'foo': 'baz', 'ignore': 'this'}), END)
|
||||
context.write(BEGIN, Bag({'foo': 'bar'}), Bag({'foo': 'baz', 'ignore': 'this'}), END)
|
||||
|
||||
context.start()
|
||||
context.step()
|
||||
@ -34,7 +34,7 @@ def test_read_csv_from_file(tmpdir):
|
||||
context = CapturingNodeExecutionContext(reader, services={'fs': fs})
|
||||
|
||||
context.start()
|
||||
context.recv(BEGIN, Bag(), END)
|
||||
context.write(BEGIN, Bag(), END)
|
||||
context.step()
|
||||
context.stop()
|
||||
|
||||
|
||||
@ -20,7 +20,7 @@ def test_file_writer_in_context(tmpdir, lines, output):
|
||||
context = NodeExecutionContext(writer, services={'fs': fs})
|
||||
|
||||
context.start()
|
||||
context.recv(BEGIN, *map(Bag, lines), END)
|
||||
context.write(BEGIN, *map(Bag, lines), END)
|
||||
for _ in range(len(lines)):
|
||||
context.step()
|
||||
context.stop()
|
||||
@ -48,7 +48,7 @@ def test_file_reader_in_context(tmpdir):
|
||||
context = CapturingNodeExecutionContext(reader, services={'fs': fs})
|
||||
|
||||
context.start()
|
||||
context.recv(BEGIN, Bag(), END)
|
||||
context.write(BEGIN, Bag(), END)
|
||||
context.step()
|
||||
context.stop()
|
||||
|
||||
|
||||
@ -13,7 +13,7 @@ def test_write_json_to_file(tmpdir):
|
||||
context = NodeExecutionContext(writer, services={'fs': fs})
|
||||
|
||||
context.start()
|
||||
context.recv(BEGIN, Bag({'foo': 'bar'}), END)
|
||||
context.write(BEGIN, Bag({'foo': 'bar'}), END)
|
||||
context.step()
|
||||
context.stop()
|
||||
|
||||
@ -34,7 +34,7 @@ def test_read_json_from_file(tmpdir):
|
||||
context = CapturingNodeExecutionContext(reader, services={'fs': fs})
|
||||
|
||||
context.start()
|
||||
context.recv(BEGIN, Bag(), END)
|
||||
context.write(BEGIN, Bag(), END)
|
||||
context.step()
|
||||
context.stop()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user