diff options
author | Prasad Desala <tdesala@redhat.com> | 2018-12-07 15:50:27 +0530 |
---|---|---|
committer | Bala Konda Reddy M <bmekala@redhat.com> | 2019-10-20 13:22:24 +0000 |
commit | 87feb4e7d8feb84c80cb13d5347fe40d44d2854e (patch) | |
tree | a97d9e7b08053f82787d5845ba96fcc4b4abf1f4 | |
parent | 3d184a5b3a168f359bb31c25ba0723507b32104d (diff) |
TC: test_add_brick_while_remove_brick_is_in_progress
Add-brick command failure is leaving the directories created
on the backend bricks which is resulting in the failure of the
subsequent cases.
Added some changes to clean the bricks.
Change-Id: I108efbcaef2010f6fd52c334446059f96fff3741
Signed-off-by: Prasad Desala <tdesala@redhat.com>
-rw-r--r-- | tests/functional/dht/test_add_brick_while_remove_brick_is_in_progress.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/functional/dht/test_add_brick_while_remove_brick_is_in_progress.py b/tests/functional/dht/test_add_brick_while_remove_brick_is_in_progress.py index 9451593a9..21297ced8 100644 --- a/tests/functional/dht/test_add_brick_while_remove_brick_is_in_progress.py +++ b/tests/functional/dht/test_add_brick_while_remove_brick_is_in_progress.py @@ -175,9 +175,18 @@ class RemoveBrickValidation(GlusterBaseClass): g.log.info(out) # Expanding volume while volume shrink is in-progress - g.log.info("Volume %s: Expand volume while volume shrink in-progress") + g.log.info("Volume %s: Expand volume while volume shrink in-progress", + self.volname) _, _, err = add_brick(self.mnode, self.volname, self.add_brick_list) self.assertIn("rebalance is in progress", err, "Successfully added" "bricks to the volume <NOT EXPECTED>") g.log.info("Volume %s: Failed to add-bricks while volume shrink " "in-progress <EXPECTED>", self.volname) + + # cleanup add-bricks list + for brick in self.add_brick_list: + brick_node, brick_path = brick.split(":") + ret, _, _ = g.run(brick_node, ("rm -rf %s", brick_path)) + if ret != 0: + g.log.error("Failed to clean %s:%s", brick_node, brick_path) + g.log.info("Successfully cleaned backend add-brick bricks list") |