@@ -56,7 +56,9 @@ def test_build(self, mock_call: MagicMock):
5656
5757 self .assertTrue (image .built )
5858 self .assertEqual (image_name , "test-challenge" )
59- mock_call .assert_called_once_with (["docker" , "build" , "-t" , "test-challenge" , "." ], cwd = build_path .absolute ())
59+ mock_call .assert_called_once_with (
60+ ["docker" , "build" , "--load" , "-t" , "test-challenge" , "." ], cwd = build_path .absolute ()
61+ )
6062
6163 @mock .patch ("ctfcli.core.image.subprocess.call" , return_value = 1 )
6264 def test_build_returns_none_if_failed (self , mock_call : MagicMock ):
@@ -68,7 +70,9 @@ def test_build_returns_none_if_failed(self, mock_call: MagicMock):
6870
6971 self .assertFalse (image .built )
7072 self .assertIsNone (image_name )
71- mock_call .assert_called_once_with (["docker" , "build" , "-t" , "test-challenge" , "." ], cwd = build_path .absolute ())
73+ mock_call .assert_called_once_with (
74+ ["docker" , "build" , "--load" , "-t" , "test-challenge" , "." ], cwd = build_path .absolute ()
75+ )
7276
7377 @mock .patch ("ctfcli.core.image.subprocess.call" , return_value = 0 )
7478 def test_push_built_image (self , mock_call : MagicMock ):
@@ -150,7 +154,7 @@ def test_builds_image_before_push(self, mock_call: MagicMock):
150154 mock_call .assert_has_calls (
151155 [
152156 call (
153- ["docker" , "build" , "-t" , "test-challenge" , "." ],
157+ ["docker" , "build" , "--load" , "- t" , "test-challenge" , "." ],
154158 cwd = build_path .absolute (),
155159 ),
156160 call (
@@ -224,7 +228,7 @@ def test_builds_image_before_export(self, mock_call: MagicMock):
224228 mock_call .assert_has_calls (
225229 [
226230 call (
227- ["docker" , "build" , "-t" , "test-challenge" , "." ],
231+ ["docker" , "build" , "--load" , "- t" , "test-challenge" , "." ],
228232 cwd = build_path .absolute (),
229233 ),
230234 call (
0 commit comments