From: Dimitri Savineau Date: Tue, 24 Mar 2020 18:28:51 +0000 (-0400) Subject: tests: update mgr dashboard socket listening test X-Git-Tag: v4.0.19~4 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=e34c95d28f7b49d34a9458d1596dda67b5ea7d57;p=ceph-ansible.git tests: update mgr dashboard socket listening test Since 15ed9ee the ceph-mgr daemon binds on the IP address on the public network instead of binding on all addresses. This commit updates the testinfra code to reflect that change. Signed-off-by: Dimitri Savineau (cherry picked from commit 0f0a14772c21fbeadcc0c92b48a8c54ab8b729d6) --- diff --git a/tests/functional/tests/mgr/test_mgr.py b/tests/functional/tests/mgr/test_mgr.py index c10b032c1..9256dcf7f 100644 --- a/tests/functional/tests/mgr/test_mgr.py +++ b/tests/functional/tests/mgr/test_mgr.py @@ -25,8 +25,9 @@ class TestMGRs(object): @pytest.mark.parametrize('port', [ '8443', '9283' ]) - def test_mgr_dashboard_is_listening(self, node, host, port): - assert host.socket('tcp://%s' % port).is_listening + def test_mgr_dashboard_is_listening(self, node, host, setup, port): + s = host.socket('tcp://%s:%s' % (setup["address"], port)) + assert s.is_listening def test_mgr_is_up(self, node, host, setup): hostname = node["vars"]["inventory_hostname"]