Move assert after logs output to make debug easier

This commit is contained in:
Ayaz Salikhov
2021-06-27 13:19:05 +03:00
parent aee3cbba77
commit 5c860df8c4
10 changed files with 11 additions and 11 deletions

View File

@@ -21,9 +21,9 @@ def test_start_notebook(container, http_client, env, expected_server):
)
c = container.run(tty=True, environment=env, command=["start-notebook.sh"])
resp = http_client.get("http://localhost:8888")
assert resp.status_code == 200, "Server is not listening"
logs = c.logs(stdout=True).decode("utf-8")
LOGGER.debug(logs)
assert resp.status_code == 200, "Server is not listening"
assert (
f"Executing the command: jupyter {expected_server}" in logs
), f"Not the expected command (jupyter {expected_server}) was launched"