MCPcopy Index your code
hub / github.com/docker/docker-py / test_remove

Method test_remove

tests/integration/models_containers_test.py:395–403  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

393 assert container.status == "running"
394
395 def test_remove(self):
396 client = docker.from_env(version=TEST_API_VERSION)
397 container = client.containers.run("alpine", "echo hello", detach=True)
398 self.tmp_containers.append(container.id)
399 assert container.id in [c.id for c in client.containers.list(all=True)]
400 container.wait()
401 container.remove()
402 containers = client.containers.list(all=True)
403 assert container.id not in [c.id for c in containers]
404
405 def test_rename(self):
406 client = docker.from_env(version=TEST_API_VERSION)

Callers

nothing calls this directly

Calls 5

from_envMethod · 0.80
runMethod · 0.80
listMethod · 0.45
waitMethod · 0.45
removeMethod · 0.45

Tested by

no test coverage detected