summaryrefslogtreecommitdiff
path: root/heatclient/tests
diff options
context:
space:
mode:
authorshizhihui <zhihui.shi@easystack.cn>2016-11-14 22:45:47 +0800
committershizhihui <zhihui.shi@easystack.cn>2016-11-14 22:45:47 +0800
commit16b50f84dad258467a64ec02b39847ec4451fb62 (patch)
tree3ca5a6d2da73f3144da0cb0325603d7a6ac58d0e /heatclient/tests
parent505ad5ce385370554e33bc208358baf062721e98 (diff)
downloadpython-heatclient-16b50f84dad258467a64ec02b39847ec4451fb62.tar.gz
Add functinoal tests for 'openstack stack snapshot delete'
For now, there are several heat osc CLIs which do not have own functional tests in heatclient/tests/functional/osc/v1. I think it is time to add some for heatclient. Add functional test for 'openstack stack snapshot delete' Change-Id: I21257b4f6126b9693256c953ed9335edad53a844 Implements: bp add-functional
Diffstat (limited to 'heatclient/tests')
-rw-r--r--heatclient/tests/functional/osc/v1/test_stack.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/heatclient/tests/functional/osc/v1/test_stack.py b/heatclient/tests/functional/osc/v1/test_stack.py
index e62d2b0..2f985f7 100644
--- a/heatclient/tests/functional/osc/v1/test_stack.py
+++ b/heatclient/tests/functional/osc/v1/test_stack.py
@@ -66,3 +66,12 @@ class OpenStackClientStackTest(base.OpenStackClientTestBase):
self._stack_delete(stack['id'])
stacks_raw = self.openstack('stack list')
self.assertNotIn(stack['id'], stacks_raw)
+
+ def test_stack_snapshot_delete(self):
+ snapshot_name = utils.rand_name(name='test-stack-snapshot')
+ stack = self._stack_create_minimal()
+ snapshot = self._stack_snapshot_create(stack['id'], snapshot_name)
+ self._stack_snapshot_delete(stack['id'], snapshot['id'])
+ stacks_raw = self.openstack(
+ 'stack snapshot list' + ' ' + self.stack_name)
+ self.assertNotIn(snapshot['id'], stacks_raw)