From bdf1cf260d08fea616201fbc9bc6efe898c02218 Mon Sep 17 00:00:00 2001 From: Ryan Collingham Date: Fri, 11 Jun 2021 22:48:49 +0100 Subject: [PATCH] Fix up tests --- tests/test_api.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/tests/test_api.py b/tests/test_api.py index bbab4cb..76bb732 100644 --- a/tests/test_api.py +++ b/tests/test_api.py @@ -58,7 +58,12 @@ def test_environment(mock_popen, mock_check_call, clients): rcvd = socket_client.get_received() assert len(rcvd) == 1 mock_popen.assert_called_once_with( - ["docker-compose", "-f", "pytest_examples/docker-compose.yml", "up"] + [ + "docker-compose", + "-f", + os.path.abspath("pytest_examples/docker-compose.yml"), + "up", + ] ) socket_client.emit("stop env", "") @@ -66,5 +71,10 @@ def test_environment(mock_popen, mock_check_call, clients): while len(rcvd) < 2: rcvd.extend(socket_client.get_received()) mock_check_call.assert_called_once_with( - ["docker-compose", "-f", "pytest_examples/docker-compose.yml", "down"] + [ + "docker-compose", + "-f", + os.path.abspath("pytest_examples/docker-compose.yml"), + "down", + ] )