# Path: zoe_master/backends/docker/api_client.py
# class DockerClient:
#     def __init__(self, docker_config: DockerHostConfig, mock_client=None) -> None:
#     def info(self) -> Dict:
#     def spawn_container(self, service_instance: ServiceInstance) -> Dict[str, Any]:
#     def _container_summary(self, container: docker.models.containers.Container):
#     def inspect_container(self, docker_id: str) -> Dict[str, Any]:
#     def terminate_container(self, docker_id: str, delete=False) -> None:
#     def event_listener(self, callback: Callable[[str], bool]) -> None:
#     def list(self, only_label=None, status=None) -> List[dict]:
#     def stats(self, docker_id: str, stream: bool):
#     def logs(self, docker_id: str, stream: bool, follow=None):
#     def list_images(self):
#     def pull_image(self, image_name):
#     def update(self, docker_id, cpu_quota=None, mem_reservation=None, mem_limit=None):
# 
# Path: zoe_master/backends/docker/config.py
# class DockerHostConfig:
#     """A class that holds static information about a host."""
#     def __init__(self):
#         self.name = None
#         self.address = None
#         self.external_address = None
#         self.tls = False
#         self.tls_cert = None
#         self.tls_key = None
#         self.tls_ca = None
#         self.labels = set()
# 
# Path: zoe_master/exceptions.py
# class ZoeException(Exception):
#     """
#     A generic exception.
#     """
#     def __init__(self, message='Something happened'):
#         super().__init__()
#         self.message = message
# 
#     def __str__(self):
#         return self.message


import time
import pytest
from zoe_master.backends.docker import api_client
from zoe_master.backends.docker.config import DockerHostConfig
from zoe_master.exceptions import ZoeException
                    "Propagation": ""
                }
            ]
        }
        self.status = 'running'

    def stop(self, timeout=5):
        """Stop method"""
        time.sleep(timeout/10)

    def remove(self, force=False):
        """Remove method"""
        if force:
            return
        return


class TestDockerEngineApiClient:
    """Docker low-level wrapper testing."""

    @pytest.fixture
    def docker_client(self):
        """The mock Docker client object."""
        return MockDocker()

    def test_init_fail(self):
        """Test that initialization fails with a bad address."""
        dhc = DockerHostConfig()
        dhc.name = 'test'
        dhc.address = '999.999.999.999:9999'

# Path: zoe_master/backends/docker/api_client.py
# class DockerClient:
#     def __init__(self, docker_config: DockerHostConfig, mock_client=None) -> None:
#     def info(self) -> Dict:
#     def spawn_container(self, service_instance: ServiceInstance) -> Dict[str, Any]:
#     def _container_summary(self, container: docker.models.containers.Container):
#     def inspect_container(self, docker_id: str) -> Dict[str, Any]:
#     def terminate_container(self, docker_id: str, delete=False) -> None:
#     def event_listener(self, callback: Callable[[str], bool]) -> None:
#     def list(self, only_label=None, status=None) -> List[dict]:
#     def stats(self, docker_id: str, stream: bool):
#     def logs(self, docker_id: str, stream: bool, follow=None):
#     def list_images(self):
#     def pull_image(self, image_name):
#     def update(self, docker_id, cpu_quota=None, mem_reservation=None, mem_limit=None):
# 
# Path: zoe_master/backends/docker/config.py
# class DockerHostConfig:
#     """A class that holds static information about a host."""
#     def __init__(self):
#         self.name = None
#         self.address = None
#         self.external_address = None
#         self.tls = False
#         self.tls_cert = None
#         self.tls_key = None
#         self.tls_ca = None
#         self.labels = set()
# 
# Path: zoe_master/exceptions.py
# class ZoeException(Exception):
#     """
#     A generic exception.
#     """
#     def __init__(self, message='Something happened'):
#         super().__init__()
#         self.message = message
# 
#     def __str__(self):
#         return self.message


# Path: zoe_master/backends/docker/tests/api_client_test.py
import time
import pytest
from zoe_master.backends.docker import api_client
from zoe_master.backends.docker.config import DockerHostConfig
from zoe_master.exceptions import ZoeException

                    "Propagation": ""
                }
            ]
        }
        self.status = 'running'

    def stop(self, timeout=5):
        """Stop method"""
        time.sleep(timeout/10)

    def remove(self, force=False):
        """Remove method"""
        if force:
            return
        return


class TestDockerEngineApiClient:
    """Docker low-level wrapper testing."""

    @pytest.fixture
    def docker_client(self):
        """The mock Docker client object."""
        return MockDocker()

    def test_init_fail(self):
        """Test that initialization fails with a bad address."""
        dhc = DockerHostConfig()
        dhc.name = 'test'
        dhc.address = '999.999.999.999:9999'

        with pytest.raises(ZoeException):