From 75898ee995b08892ab4b936094a58d4321fc24a6 Mon Sep 17 00:00:00 2001 From: kshithijiyer Date: Tue, 18 Feb 2020 13:21:05 +0530 Subject: [TestFix] Changing code used to create arbiter volumes As distributed-arbiter and arbiter weren't present before patch [1], arbiter and distributed-arbiter volumes were created by the hack show below where a distributed-replicated or replicated volume's configuration was modified to create an arbiter volume. ``` @runs_on([['replicated', 'distributed-replicated'], ['glusterfs', 'nfs']]) class TestSelfHeal(GlusterBaseClass): ................. @classmethod def setUpClass(cls): ............... # Overriding the volume type to specifically test the volume # type Change from distributed-replicated to arbiter if cls.volume_type == "distributed-replicated": cls.volume['voltype'] = { 'type': 'distributed-replicated', 'dist_count': 2, 'replica_count': 3, 'arbiter_count': 1, 'transport': 'tcp'} ``` Now this code is to be updated where we need to remove code which was used to override volume configuration and just add arbiter or distributed-arbiter in `@runs_on([],[])` as shown below: ``` @runs_on([['replicated', 'distributed-arbiter'], ['glusterfs', 'nfs']]) class TestSelfHeal(GlusterBaseClass): ``` Links: [1] https://github.com/gluster/glusto-tests/commit/08b727842bc66603e3b8d1160ee4b15051b0cd20 Change-Id: I4c44c2f3506bd0183fd991354fb723f8ec235a4b Signed-off-by: kshithijiyer --- .../arbiter/test_data_self_heal_algorithm_diff_default.py | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) (limited to 'tests/functional/arbiter/test_data_self_heal_algorithm_diff_default.py') diff --git a/tests/functional/arbiter/test_data_self_heal_algorithm_diff_default.py b/tests/functional/arbiter/test_data_self_heal_algorithm_diff_default.py index 13d4a6c81..def1f7cd2 100644 --- a/tests/functional/arbiter/test_data_self_heal_algorithm_diff_default.py +++ b/tests/functional/arbiter/test_data_self_heal_algorithm_diff_default.py @@ -1,4 +1,4 @@ -# Copyright (C) 2015-2018 Red Hat, Inc. +# Copyright (C) 2015-2020 Red Hat, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -37,7 +37,7 @@ from glustolibs.misc.misc_libs import upload_scripts from glustolibs.io.utils import (collect_mounts_arequal, validate_io_procs) -@runs_on([['replicated', 'distributed-replicated'], +@runs_on([['arbiter', 'distributed-arbiter'], ['glusterfs', 'cifs', 'nfs']]) class TestSelfHeal(GlusterBaseClass): """ @@ -51,16 +51,6 @@ class TestSelfHeal(GlusterBaseClass): # Calling GlusterBaseClass setUpClass cls.get_super_method(cls, 'setUpClass')() - # Overriding the volume type to specifically test the volume type - # Change from distributed-replicated to arbiter - if cls.volume_type == "distributed-replicated": - cls.volume['voltype'] = { - 'type': 'distributed-replicated', - 'dist_count': 2, - 'replica_count': 3, - 'arbiter_count': 1, - 'transport': 'tcp'} - # Upload io scripts for running IO on mounts g.log.info("Upload io scripts to clients %s for running IO on mounts", cls.clients) -- cgit