diff --git a/tests/test_php.py b/tests/test_php.py index daadbb43..10a94e58 100644 --- a/tests/test_php.py +++ b/tests/test_php.py @@ -277,10 +277,11 @@ def get_env_var(env_var: str) -> str: ).is_file apache_envvars = get_env_var("APACHE_ENVVARS") - assert container_per_test.connection.file(apache_envvars).is_file - assert container_per_test.connection.run_expect( - [0], f"source {apache_envvars}" - ) + if apache_envvars: + assert container_per_test.connection.file(apache_envvars).is_file + assert container_per_test.connection.run_expect( + [0], f"source {apache_envvars}" + ) @pytest.mark.parametrize("container_image", [PHP_8_CLI])