| 528 | assert container.attrs['HostConfig']['CpuShares'] == 3 |
| 529 | |
| 530 | def test_wait(self): |
| 531 | client = docker.from_env(version=TEST_API_VERSION) |
| 532 | container = client.containers.run("alpine", "sh -c 'exit 0'", |
| 533 | detach=True) |
| 534 | self.tmp_containers.append(container.id) |
| 535 | assert container.wait()['StatusCode'] == 0 |
| 536 | container = client.containers.run("alpine", "sh -c 'exit 1'", |
| 537 | detach=True) |
| 538 | self.tmp_containers.append(container.id) |
| 539 | assert container.wait()['StatusCode'] == 1 |
| 540 | |
| 541 | def test_create_with_volume_driver(self): |
| 542 | client = docker.from_env(version=TEST_API_VERSION) |