From: Guillaume Abrioux Date: Fri, 22 Jun 2018 23:43:49 +0000 (+0200) Subject: tests: refact test_all_*_osds_are_up_and_in X-Git-Tag: v3.1.0rc11~12 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b8dde664d212527659d64af9ba8843bbf9eee721;p=ceph-ansible.git tests: refact test_all_*_osds_are_up_and_in these tests are skipped on bluestore osds scenarios. they were going to fail anyway since they are run on mon nodes and `devices` is defined in inventory for each osd node. It means `num_devices * num_osd_hosts` returns `0`. The result is that the test expects to have 0 OSDs up. The idea here is to move these tests so they are run on OSD nodes. Each OSD node checks their respective OSD to be UP, if an OSD has 2 devices defined in `devices` variable, it means we are checking for 2 OSD to be up on that node, if each node has all its OSD up, we can say all OSD are up. Signed-off-by: Guillaume Abrioux (cherry picked from commit fe79a5d24086fc61ae84a59bd61a053cddb62941) --- diff --git a/tests/functional/tests/osd/test_osds.py b/tests/functional/tests/osd/test_osds.py index e87f6e1b0..e87c05be5 100644 --- a/tests/functional/tests/osd/test_osds.py +++ b/tests/functional/tests/osd/test_osds.py @@ -76,4 +76,4 @@ class TestOSDs(object): cluster=node["cluster_name"] ) output = json.loads(host.check_output(cmd)) - assert node["num_devices"] == self._get_nb_up_osds_from_ids(node, output) \ No newline at end of file + assert node["num_devices"] == self._get_nb_up_osds_from_ids(node, output)