Better tests directory structure (#2231)

This commit is contained in:
Ayaz Salikhov
2025-02-21 17:46:43 +00:00
committed by GitHub
parent 80f4426b8e
commit 165bbc1e71
67 changed files with 174 additions and 148 deletions

View File

@@ -0,0 +1,22 @@
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
import logging
from tests.utils.tracked_container import TrackedContainer
LOGGER = logging.getLogger(__name__)
def run_command(
container: TrackedContainer,
command: str,
timeout: int = 5,
) -> str:
"""Runs the given package manager with its version argument."""
LOGGER.info(f"Test that the command '{command}' is working properly ...")
return container.run_and_wait(
timeout=timeout,
tty=True,
command=["bash", "-c", command],
)