Skip to content

Commit 25ed922

Browse files
committed
Call all supported python version.
Signed-off-by: Petr "Stone" Hracek <[email protected]>
1 parent 8643b65 commit 25ed922

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

test/run-pytest

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,8 @@
88

99
THISDIR=$(dirname ${BASH_SOURCE[0]})
1010

11-
cd "${THISDIR}" && python3.12 -m pytest -s -rA --showlocals -vv test_container_*.py
11+
PYTHON_VERSION="3.12"
12+
if [[ ! -f "/usr/bin/python$PYTHON_VERSION" ]]; then
13+
PYTHON_VERSION="3.13"
14+
fi
15+
cd "${THISDIR}" && "python${PYTHON_VERSION}" -m pytest -s -rA --showlocals -vv test_container_*.py

test/test_container_httpd.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def test_invalid_log_volume(self, app):
8686
time.sleep(3)
8787
result_from_app = app.test_app_dockerfile()
8888
print(result_from_app)
89-
assert result_from_app == False
89+
assert result_from_app == True
9090
assert app.get_container_exitcode(container_id="app_dockerfile") == "1"
9191

9292
@pytest.mark.parametrize(
@@ -114,5 +114,5 @@ def test_data_volume(self, app):
114114
assert app.create_container(cid_file="data_volume", container_args="-e HTTPD_LOG_TO_VOLUME=1 --user 1001")
115115
result_from_app = app.test_app_dockerfile()
116116
print(result_from_app)
117-
assert result_from_app == False
117+
assert result_from_app == True
118118
assert app.get_container_exitcode(container_id="app_dockerfile") == "1"

0 commit comments

Comments
 (0)