Add an acceptance test and docs for the down subcommand

Signed-off-by: Daniel Nephin <dnephin@docker.com>
This commit is contained in:
Daniel Nephin 2016-01-12 17:33:17 -05:00
commit c64af0a459
13 changed files with 102 additions and 13 deletions

View file

@ -319,8 +319,16 @@ class CLITestCase(DockerClientTestCase):
assert '--rmi flag must be' in result.stderr
def test_down(self):
result = self.dispatch(['down'])
# TODO:
self.base_dir = 'tests/fixtures/shutdown'
self.dispatch(['up', '-d'])
wait_on_condition(ContainerCountCondition(self.project, 1))
result = self.dispatch(['down', '--rmi=local', '--volumes'])
assert 'Stopping shutdown_web_1' in result.stderr
assert 'Removing shutdown_web_1' in result.stderr
assert 'Removing volume shutdown_data' in result.stderr
assert 'Removing image shutdown_web' in result.stderr
assert 'Removing network shutdown_default' in result.stderr
def test_up_detached(self):
self.dispatch(['up', '-d'])