summaryrefslogtreecommitdiff
path: root/heatclient/tests
diff options
context:
space:
mode:
authorRoberto Polli <robipolli@gmail.com>2017-09-15 15:01:00 +0200
committerhuangtianhua <huangtianhua@huawei.com>2017-09-28 08:28:27 +0000
commit2a39275ec3cbd44cd12b46b90db5d249a762a164 (patch)
tree15f8c6bc857029bcf46597f4974cae456e977aa5 /heatclient/tests
parent0bfb7899b29784ee6d489142c977479d51c8d05e (diff)
downloadpython-heatclient-2a39275ec3cbd44cd12b46b90db5d249a762a164.tar.gz
Support --show-nested in openstack stack update --dry-run
Added --show-nested support in `openstack stack update`. The work is based on `heat stack-update` implementation. Closes-Bug: #1720085 Change-Id: I50c8f5ac9ba4cb7e478af03ff4c1f099270ae226
Diffstat (limited to 'heatclient/tests')
-rw-r--r--heatclient/tests/unit/osc/v1/test_stack.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/heatclient/tests/unit/osc/v1/test_stack.py b/heatclient/tests/unit/osc/v1/test_stack.py
index 54fe9be..159056a 100644
--- a/heatclient/tests/unit/osc/v1/test_stack.py
+++ b/heatclient/tests/unit/osc/v1/test_stack.py
@@ -335,6 +335,17 @@ class TestStackUpdate(TestStack):
self.stack_client.preview_update.assert_called_with(**self.defaults)
self.stack_client.update.assert_not_called()
+ def test_stack_update_dry_run_show_nested(self):
+ arglist = ['my_stack', '-t', self.template_path, '--dry-run',
+ '--show-nested']
+ parsed_args = self.check_parser(self.cmd, arglist, [])
+
+ self.cmd.take_action(parsed_args)
+
+ self.stack_client.preview_update.assert_called_with(
+ show_nested=True, **self.defaults)
+ self.stack_client.update.assert_not_called()
+
@mock.patch('heatclient.common.event_utils.poll_for_events',
return_value=('UPDATE_COMPLETE',
'Stack my_stack UPDATE_COMPLETE'))