MCPcopy Create free account
hub / github.com/docker/docker-py / test_ctor

Method test_ctor

tests/unit/api_test.py:121–127  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

119
120class DockerApiTest(BaseAPIClientTest):
121 def test_ctor(self):
122 with pytest.raises(docker.errors.DockerException) as excinfo:
123 APIClient(version=1.12)
124
125 assert str(
126 excinfo.value
127 ) == 'Version parameter must be a string or None. Found float'
128
129 def test_url_valid_resource(self):
130 url = self.client._url('/hello/{0}/world', 'somename')

Callers

nothing calls this directly

Calls 1

APIClientClass · 0.90

Tested by

no test coverage detected