diff options
author | Valerii Ponomarov <vponomar@redhat.com> | 2018-12-19 20:02:14 +0530 |
---|---|---|
committer | Valerii Ponomarov <vponomar@redhat.com> | 2018-12-19 20:02:14 +0530 |
commit | 19a779c3051565cdbfa080460e46a00e824b2589 (patch) | |
tree | 2a1b11bdefd0cb647dc6f4f9652a26b6b70bc762 /tests | |
parent | 5826be464a45fe89183cd39a2c56b73e886dfafa (diff) |
Fix bug in 'test_volume_creation_no_free_devices' test case
Which uses improper vars in block of code where we disable
redundant nodes. It is just not executed in case we use
3-node Gluster cluster.
So, fix var usages making this test be compatible with 4+ node GLuster
clusters.
Change-Id: Id9ac9ae9b614c492c0f39573c0224378f887fee5
Diffstat (limited to 'tests')
-rw-r--r-- | tests/functional/common/heketi/test_volume_creation.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/functional/common/heketi/test_volume_creation.py b/tests/functional/common/heketi/test_volume_creation.py index b3db8446..07dba094 100644 --- a/tests/functional/common/heketi/test_volume_creation.py +++ b/tests/functional/common/heketi/test_volume_creation.py @@ -110,11 +110,10 @@ class TestVolumeCreationTestCases(heketi_libs.HeketiBaseClass): node_info_list.append(node_info) # Disable 4th and other nodes - if len(node_id_list) > 3: - for node in node_id_list[3:]: - heketi_ops.heketi_node_disable(node, server_url, node_id) - self.addCleanup( - heketi_ops.heketi_node_enable, node, server_url, node_id) + for node_id in node_id_list[3:]: + heketi_ops.heketi_node_disable(node, server_url, node_id) + self.addCleanup( + heketi_ops.heketi_node_enable, node, server_url, node_id) # Disable second and other devices on the first 3 nodes for node_info in node_info_list[0:3]: |