summaryrefslogtreecommitdiffstats
path: root/tests/functional/heketi/test_block_volumes_heketi.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/functional/heketi/test_block_volumes_heketi.py')
-rw-r--r--tests/functional/heketi/test_block_volumes_heketi.py13
1 files changed, 5 insertions, 8 deletions
diff --git a/tests/functional/heketi/test_block_volumes_heketi.py b/tests/functional/heketi/test_block_volumes_heketi.py
index 5520e8bc..b6ff9ee0 100644
--- a/tests/functional/heketi/test_block_volumes_heketi.py
+++ b/tests/functional/heketi/test_block_volumes_heketi.py
@@ -114,16 +114,13 @@ class TestBlockVolumeOps(BaseClass):
self.skipTest("Skipping the test since free_space_available %s"
"is less than the default_bhv_size %s"
% (free_space_available, default_bhv_size))
- block_host_create_info = heketi_volume_create(
- self.heketi_client_node, self.heketi_server_url,
- default_bhv_size, json=True, block=True)
+ h_volume_name = (
+ "autotests-heketi-volume-%s" % utils.get_random_str())
+ block_host_create_info = self.create_heketi_volume_with_name_and_wait(
+ h_volume_name, default_bhv_size, json=True, block=True)
+
block_vol_size = block_host_create_info["blockinfo"]["freesize"]
block_hosting_vol_id = block_host_create_info["id"]
- self.addCleanup(heketi_volume_delete,
- self.heketi_client_node,
- self.heketi_server_url,
- block_hosting_vol_id,
- raise_on_error=True)
block_vol_info = {"blockhostingvolume": "init_value"}
while (block_vol_info['blockhostingvolume'] != block_hosting_vol_id):
block_vol = heketi_blockvolume_create(