]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
test_mons: test mon listening on port 3300
authorDimitri Savineau <dsavinea@redhat.com>
Tue, 16 Apr 2019 20:52:42 +0000 (16:52 -0400)
committerGuillaume Abrioux <gabrioux@redhat.com>
Wed, 17 Apr 2019 06:19:48 +0000 (08:19 +0200)
Since nautilus and msgr2 the monitors also bind on port 3300 in
addition of 6789.
This patch updates test_mons to reflect that change.

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
tests/functional/tests/mon/test_mons.py

index 1c57b40c3d35dffc3b169f7215a74a99edaa8174..aa916ea42c3594a1dbaede1d8129060d6a1dc190 100644 (file)
@@ -8,8 +8,12 @@ class TestMons(object):
     def test_ceph_mon_package_is_installed(self, node, host):
         assert host.package("ceph-mon").is_installed
 
-    def test_mon_listens_on_6789(self, node, host, setup):
-        assert host.socket("tcp://%s:6789" % setup["address"]).is_listening
+    @pytest.mark.parametrize("mon_port", [3300, 6789])
+    def test_mon_listens(self, node, host, setup, mon_port):
+        assert host.socket("tcp://{address}:{port}".format(
+            address=setup["address"],
+            port=mon_port
+        )).is_listening
 
     def test_mon_service_is_running(self, node, host):
         service_name = "ceph-mon@{hostname}".format(