Skip to content

Commit 1ab1916

Browse files
committed
add pytest.importorskip("zenoh") guard
1 parent d445111 commit 1ab1916

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

dimos/core/test_zenoh_transport.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
- _get_transport_for() branching
2020
- LCM system configurators always run with blueprint checks (LCM is used outside transport_map)
2121
22-
Requires the ``zenoh`` extra (``eclipse-zenoh``): ``ZenohTransport`` is only defined
23-
when that dependency is installed, so this module does not load without it.
22+
Requires the ``zenoh`` extra (``eclipse-zenoh``). When it is missing, pytest skips
23+
this module via ``importorskip`` so collection does not fail on ``ZenohTransport`` imports.
2424
"""
2525

2626
from __future__ import annotations
@@ -32,6 +32,8 @@
3232
from pydantic import ValidationError
3333
import pytest
3434

35+
pytest.importorskip("zenoh")
36+
3537
from dimos.constants import ZENOH_DIMOS_KEY_PREFIX
3638
from dimos.core.coordination.blueprints import autoconnect
3739
from dimos.core.coordination.module_coordinator import _get_transport_for, _run_configurators

0 commit comments

Comments
 (0)