aboutsummaryrefslogtreecommitdiffstats
path: root/test/mocks/mass-pnf-sim/conftest.py
diff options
context:
space:
mode:
Diffstat (limited to 'test/mocks/mass-pnf-sim/conftest.py')
-rw-r--r--test/mocks/mass-pnf-sim/conftest.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/mocks/mass-pnf-sim/conftest.py b/test/mocks/mass-pnf-sim/conftest.py
index 3323440da..265813331 100644
--- a/test/mocks/mass-pnf-sim/conftest.py
+++ b/test/mocks/mass-pnf-sim/conftest.py
@@ -1,6 +1,7 @@
import MassPnfSim
import pytest
from test_settings import * # pylint: disable=W0614
+from docker import from_env
@pytest.fixture(scope="module")
def parser():
@@ -36,3 +37,11 @@ def args_trigger_custom(parser):
@pytest.fixture
def args_clean(parser):
return parser.parse_args(['clean'])
+
+@pytest.fixture
+def docker_containers():
+ docker_client = from_env()
+ container_list = []
+ for container in docker_client.containers.list():
+ container_list.append(container.attrs['Name'][1:])
+ return container_list