Skip to content

Commit 4cd6f40

Browse files
committed
test fixed
1 parent 7c161da commit 4cd6f40

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

tests/test_streams.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -615,11 +615,13 @@ def test_flumine_stream(self):
615615
self.assertEqual(str(stream), "FlumineStream")
616616
self.assertEqual(repr(stream), "<FlumineStream [0]>")
617617

618-
def test_flumine_stream_on_process(self):
618+
@mock.patch("flumine.streams.datastream.RawDataEvent")
619+
def test_flumine_stream_on_process(self, raw_data_event):
619620
mock_listener = mock.Mock()
620621
stream = datastream.FlumineStream(mock_listener, 0)
621622
stream.on_process([1, 2, 3])
622-
mock_listener.output_queue.put.called_with(datastream.RawDataEvent([1, 2, 3]))
623+
raw_data_event.assert_called_with([1, 2, 3])
624+
mock_listener.output_queue.put.assert_called_with(raw_data_event.return_value)
623625

624626
@mock.patch("flumine.streams.datastream.FlumineMarketStream.on_process")
625627
def test_flumine_market_stream(self, mock_on_process):

0 commit comments

Comments
 (0)