]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Split single and multiple vips test into 2 functions
authorLuis Domingues <domingues.luis@protonmail.ch>
Tue, 9 Aug 2022 15:23:59 +0000 (16:23 +0100)
committerLuis Domingues <domingues.luis@protonmail.ch>
Tue, 9 Aug 2022 21:35:58 +0000 (22:35 +0100)
Signed-off-by: Luis Domingues <domingues.luis@protonmail.ch>
src/pybind/mgr/cephadm/tests/test_services.py

index 655dbccf52970705d2c532dcd875271281488844..176cf6fc81a20b4243bfe0faf524c0b07e16fe5f 100644 (file)
@@ -1004,6 +1004,17 @@ class TestIngressService:
 
                 assert haproxy_generated_conf[0] == haproxy_expected_conf
 
+    @patch("cephadm.serve.CephadmServe._run_cephadm")
+    def test_ingress_config_multi_vips(self, _run_cephadm, cephadm_module: CephadmOrchestrator):
+        _run_cephadm.side_effect = async_side_effect(('{}', '', 0))
+
+        with with_host(cephadm_module, 'test'):
+            cephadm_module.cache.update_host_networks('test', {
+                '1.2.3.0/24': {
+                    'if0': ['1.2.3.4/32']
+                }
+            })
+
             # Check the ingress with multiple VIPs
             s = RGWSpec(service_id="foo", placement=PlacementSpec(count=1),
                         rgw_frontend_type='beast')