From 10d39e98dde5042d98d234887ead17ff7d278e55 Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Mon, 1 May 2017 10:45:44 -0500 Subject: [PATCH] tests: test that all docker OSDs are up and in Signed-off-by: Andrew Schoen --- tests/functional/tests/mon/test_mons.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/functional/tests/mon/test_mons.py b/tests/functional/tests/mon/test_mons.py index 73229f0a0..d97429aff 100644 --- a/tests/functional/tests/mon/test_mons.py +++ b/tests/functional/tests/mon/test_mons.py @@ -37,3 +37,13 @@ class TestOSDs(object): output = Command.check_output(cmd) phrase = "{num_osds} osds: {num_osds} up, {num_osds} in".format(num_osds=node["total_osds"]) assert phrase in output + + @pytest.mark.docker + def test_all_docker_osds_are_up_and_in(self, node, Command): + cmd = "sudo docker exec ceph-mon-ceph-{} ceph --cluster={} --connect-timeout 5 -s".format( + node["vars"]["inventory_hostname"], + node["cluster_name"] + ) + output = Command.check_output(cmd) + phrase = "{num_osds} osds: {num_osds} up, {num_osds} in".format(num_osds=node["total_osds"]) + assert phrase in output -- 2.47.3