mirror of
https://github.com/jupyter/docker-stacks.git
synced 2025-10-17 23:12:56 +00:00
Fix some style issues in tests
This commit is contained in:
@@ -128,18 +128,16 @@ def test_healthy_with_proxy(
|
||||
|
||||
|
||||
@pytest.mark.parametrize(
|
||||
"env,cmd,user",
|
||||
"env,cmd",
|
||||
[
|
||||
(["NB_USER=testuser", "CHOWN_HOME=1"], None, None),
|
||||
(["NB_USER=testuser", "CHOWN_HOME=1"], None),
|
||||
(
|
||||
["NB_USER=testuser", "CHOWN_HOME=1"],
|
||||
["start-notebook.py", "--ServerApp.base_url=/test"],
|
||||
None,
|
||||
),
|
||||
(
|
||||
["NB_USER=testuser", "CHOWN_HOME=1", "JUPYTER_PORT=8123"],
|
||||
["start-notebook.py", "--ServerApp.base_url=/test"],
|
||||
None,
|
||||
),
|
||||
],
|
||||
)
|
||||
@@ -147,13 +145,11 @@ def test_not_healthy(
|
||||
container: TrackedContainer,
|
||||
env: Optional[list[str]],
|
||||
cmd: Optional[list[str]],
|
||||
user: Optional[str],
|
||||
) -> None:
|
||||
running_container = container.run_detached(
|
||||
tty=True,
|
||||
environment=env,
|
||||
command=cmd,
|
||||
user=user,
|
||||
)
|
||||
|
||||
# sleeping some time to let the server start
|
||||
@@ -164,6 +160,6 @@ def test_not_healthy(
|
||||
time.sleep(wait_time)
|
||||
time_spent += wait_time
|
||||
if get_health(running_container) == "healthy":
|
||||
raise RuntimeError("Container should not be healthy for these testcases.")
|
||||
raise RuntimeError("Container should not be healthy for this testcase")
|
||||
|
||||
assert get_health(running_container) != "healthy"
|
||||
|
Reference in New Issue
Block a user