mirror of
https://github.com/microsoft/autogen.git
synced 2026-04-20 03:02:16 -04:00
fixed skipping code execution in docker test if already runnning in a container (#1383)
This commit is contained in:
@@ -359,7 +359,8 @@ def test_execute_code(use_docker=None):
|
||||
|
||||
|
||||
@pytest.mark.skipif(
|
||||
sys.platform in ["win32"] or (not is_docker_running() and not in_docker_container()), reason="docker is not running"
|
||||
sys.platform in ["win32"] or (not is_docker_running()) or in_docker_container(),
|
||||
reason="docker is not running or in docker container already",
|
||||
)
|
||||
def test_execute_code_with_custom_filename_on_docker():
|
||||
exit_code, msg, image = execute_code("print('hello world')", filename="tmp/codetest.py", use_docker=True)
|
||||
@@ -368,7 +369,8 @@ def test_execute_code_with_custom_filename_on_docker():
|
||||
|
||||
|
||||
@pytest.mark.skipif(
|
||||
sys.platform in ["win32"] or (not is_docker_running() and not in_docker_container()), reason="docker is not running"
|
||||
sys.platform in ["win32"] or (not is_docker_running()) or in_docker_container(),
|
||||
reason="docker is not running or in docker container already",
|
||||
)
|
||||
def test_execute_code_with_misformed_filename_on_docker():
|
||||
exit_code, msg, image = execute_code(
|
||||
|
||||
Reference in New Issue
Block a user