Skip to content

Commit

Permalink
Increase timeout for notebook tests
Browse files Browse the repository at this point in the history
to wait for socket access
[run-notebook-tests]
  • Loading branch information
ckunki committed Mar 27, 2024
1 parent 11695ed commit 8d01f6b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
5 changes: 4 additions & 1 deletion test/docker/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,10 @@ def wait_for(

DOCKER_SOCKET_CONTAINER = "/var/run/docker.sock"

def wait_for_socket_access(container: Container):
def wait_for_socket_access(
container: Container,
timeout: timedelta = timedelta(seconds=5),
):
wait_for(
container,
f"entrypoint.py: Enabled access to {DOCKER_SOCKET_CONTAINER}",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import time
from inspect import cleandoc
from pathlib import Path
from datetime import timedelta

import pytest

Expand Down Expand Up @@ -66,7 +67,7 @@ def notebook_test_container(request, notebook_test_image):

@pytest.fixture()
def notebook_test_container_with_log(notebook_test_container):
wait_for_socket_access(notebook_test_container)
wait_for_socket_access(notebook_test_container, timeout=timedelta(seconds=60))
logs = notebook_test_container.logs().decode("utf-8").strip()
print(f"Container Logs: {logs or '(empty)'}", flush=True)
yield notebook_test_container
Expand Down

0 comments on commit 8d01f6b

Please sign in to comment.