Commit b40e4396 authored by Tim Schoof's avatar Tim Schoof
Browse files

Mock asapo broker instance instead of class

parent 93143d1a
......@@ -28,7 +28,7 @@ def dummy_stream():
@pytest.fixture
def mock_broker():
broker = create_autospec(asapo_consumer.PyDataBroker)
broker = create_autospec(asapo_consumer.PyDataBroker, instance=True)
broker.generate_group_id.return_value = "group_id"
return broker
......
......@@ -38,7 +38,7 @@ def test_ingest_mode_from_name_unknown():
@pytest.fixture
def mock_producer():
producer = create_autospec(asapo_producer.PyProducer)
producer = create_autospec(asapo_producer.PyProducer, instance=True)
return producer
......@@ -76,7 +76,7 @@ def callback_executor(mock_producer, callback_futures):
@pytest.fixture
def mock_broker():
return create_autospec(asapo_consumer.PyDataBroker)
return create_autospec(asapo_consumer.PyDataBroker, instance=True)
@pytest.fixture
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment