From d8c2dc05637159aef47772da46ee4b8d076fe77c Mon Sep 17 00:00:00 2001 From: Adam Outler Date: Sun, 26 Oct 2025 19:58:57 +0000 Subject: [PATCH] Apply coderabit's latest hare-brained idea --- test/docker_tests/test_container_environment.py | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/test/docker_tests/test_container_environment.py b/test/docker_tests/test_container_environment.py index d93ab57d..9b3400b2 100644 --- a/test/docker_tests/test_container_environment.py +++ b/test/docker_tests/test_container_environment.py @@ -655,15 +655,11 @@ def test_readonly_nginx_conf_mount(tmp_path: pathlib.Path) -> None: Expected: "Write permission denied" error with path, guidance to add volume mounts. """ paths = _setup_mount_tree(tmp_path, "readonly_nginx_conf") - _setup_zero_perm_dir(paths, "nginx_conf") - volumes = _build_volume_args(paths) - try: - result = _run_container("readonly-nginx-conf", volumes) - _assert_contains(result, "Write permission denied", result.args) - _assert_contains(result, "/services/config/nginx/conf.active", result.args) - assert result.returncode != 0 - finally: - _restore_zero_perm_dir(paths, "nginx_conf") + volumes = _build_volume_args(paths, read_only={"nginx_conf"}) + result = _run_container("readonly-nginx-conf", volumes) + _assert_contains(result, "Write permission denied", result.args) + _assert_contains(result, "/services/config/nginx/conf.active", result.args) + assert result.returncode != 0 def test_readonly_services_run_mount(tmp_path: pathlib.Path) -> None: