Skip to content

Commit 7e82fc5

Browse files
committed
make tests an importable (but not installed) module, use relative imports
1 parent 987aab1 commit 7e82fc5

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

tests/__init__.py

Whitespace-only changes.

tests/conftest.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
from urllib.parse import urlparse
1414

1515
import pytest
16-
import utils
1716
from certipy import Certipy
1817
from consul.aio import Consul
1918
from jupyterhub.utils import exponential_backoff
@@ -24,6 +23,8 @@
2423
from jupyterhub_traefik_proxy.fileprovider import TraefikFileProviderProxy
2524
from jupyterhub_traefik_proxy.traefik_utils import deep_merge
2625

26+
from . import utils
27+
2728
HERE = Path(__file__).parent.resolve()
2829
config_files = HERE / "config_files"
2930

tests/test_proxy.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
from urllib.parse import quote, urlparse
1515

1616
import pytest
17-
import utils
1817
import websockets
1918
from jupyterhub.objects import Hub, Server
2019
from jupyterhub.user import User
@@ -23,6 +22,9 @@
2322

2423
from jupyterhub_traefik_proxy.proxy import TraefikProxy
2524

25+
from . import utils
26+
27+
2628
# Mark all tests in this file as slow
2729
pytestmark = [pytest.mark.slow]
2830

0 commit comments

Comments
 (0)