summaryrefslogtreecommitdiff
path: root/openstackclient/tests/functional/volume/v2
diff options
context:
space:
mode:
authorHuanxuan Ao <huanxuan.ao@easystack.cn>2016-09-22 10:56:45 +0800
committerHuanxuan Ao <huanxuan.ao@easystack.cn>2016-09-25 09:30:45 +0800
commit52eaec1189be98664f39d7e2e07b23cbea585f10 (patch)
tree2f246abcb77a15ce8f4025716d71f3d46bcea8ee /openstackclient/tests/functional/volume/v2
parent2731fc3912aa8392179ca2d870e9daa76e1410e4 (diff)
downloadpython-openstackclient-52eaec1189be98664f39d7e2e07b23cbea585f10.tar.gz
Add functional test for snapshot in volume v1
Add functional test for snapshot commands in volume v1. Tests can always help to find or avoid bugs. Change-Id: Ieb0ab9c763d381a6343b4c4a8a5874f3e682f24f
Diffstat (limited to 'openstackclient/tests/functional/volume/v2')
-rw-r--r--openstackclient/tests/functional/volume/v2/test_snapshot.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/openstackclient/tests/functional/volume/v2/test_snapshot.py b/openstackclient/tests/functional/volume/v2/test_snapshot.py
index 4582b67d..fcbc31cb 100644
--- a/openstackclient/tests/functional/volume/v2/test_snapshot.py
+++ b/openstackclient/tests/functional/volume/v2/test_snapshot.py
@@ -52,9 +52,12 @@ class SnapshotTests(common.BaseVolumeTests):
'snapshot set --name ' + cls.OTHER_NAME + ' ' + cls.NAME)
cls.assertOutput('', raw_output)
# Delete test
- raw_output = cls.openstack('snapshot delete ' + cls.OTHER_NAME)
- cls.assertOutput('', raw_output)
- cls.openstack('volume delete --force ' + cls.VOLLY, fail_ok=True)
+ raw_output_snapshot = cls.openstack(
+ 'snapshot delete ' + cls.OTHER_NAME)
+ cls.wait_for_status('volume show ' + cls.VOLLY, 'available\n', 6)
+ raw_output_volume = cls.openstack('volume delete --force ' + cls.VOLLY)
+ cls.assertOutput('', raw_output_snapshot)
+ cls.assertOutput('', raw_output_volume)
def test_snapshot_list(self):
opts = self.get_opts(self.HEADERS)