Skip to content

Commit

Permalink
tests: mark test connection required
Browse files Browse the repository at this point in the history
  • Loading branch information
Lancetnik committed Jul 24, 2024
1 parent 3b8d969 commit 7ee6999
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/brokers/confluent/test_test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,3 +206,7 @@ async def subscriber2(): ...

assert subscriber1.mock.call_count == 1
assert subscriber2.mock.call_count == 0

@pytest.mark.confluent()
async def test_broker_gets_patched_attrs_within_cm(self):
await super().test_broker_gets_patched_attrs_within_cm()
4 changes: 4 additions & 0 deletions tests/brokers/kafka/test_test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -254,3 +254,7 @@ async def subscriber2(): ...

assert subscriber1.mock.call_count == 1
assert subscriber2.mock.call_count == 0

@pytest.mark.kafka()
async def test_broker_gets_patched_attrs_within_cm(self):
await super().test_broker_gets_patched_attrs_within_cm()
4 changes: 4 additions & 0 deletions tests/brokers/nats/test_test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,3 +255,7 @@ def subscriber(m):
await br.publish(1, f"{queue}.b")
await br.publish(2, f"{queue}.a")
subscriber.mock.assert_called_once_with(2)

@pytest.mark.nats()
async def test_broker_gets_patched_attrs_within_cm(self):
await super().test_broker_gets_patched_attrs_within_cm()
4 changes: 4 additions & 0 deletions tests/brokers/rabbit/test_test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,10 @@ async def h2(msg): ...

assert len(routes) == 2

@pytest.mark.rabbit()
async def test_broker_gets_patched_attrs_within_cm(self):
await super().test_broker_gets_patched_attrs_within_cm()


@pytest.mark.parametrize(
("pattern", "current", "result"),
Expand Down
4 changes: 4 additions & 0 deletions tests/brokers/redis/test_test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,3 +230,7 @@ async def test_publish_to_none(
async with self.patch_broker(broker) as br:
with pytest.raises(ValueError): # noqa: PT011
await br.publish("hello")

@pytest.mark.redis()
async def test_broker_gets_patched_attrs_within_cm(self):
await super().test_broker_gets_patched_attrs_within_cm()

0 comments on commit 7ee6999

Please sign in to comment.