diff tests/unit/test_ap-gateway.py @ 4321:2246eeeccc74 default tip @

tests (unit): fix tests: - test_ap-gateway: fix missing implementation of `client.is_local` - test_plugin_xep_0215: fix missing return value of `has_feature`
author Goffi <goffi@goffi.org>
date Mon, 30 Sep 2024 14:15:47 +0200
parents f1d0cde61af7
children
line wrap: on
line diff
--- a/tests/unit/test_ap-gateway.py	Mon Sep 30 14:14:38 2024 +0200
+++ b/tests/unit/test_ap-gateway.py	Mon Sep 30 14:15:47 2024 +0200
@@ -36,6 +36,7 @@
 
 from libervia.backend.core import exceptions
 from libervia.backend.core.constants import Const as C
+from libervia.backend.core.xmpp import SatXMPPComponent
 from libervia.backend.memory.sqla_mapping import SubscriptionState
 from libervia.backend.plugins import plugin_comp_ap_gateway
 from libervia.backend.plugins.plugin_comp_ap_gateway import constants as ap_const
@@ -386,6 +387,7 @@
     client.host = "test.example"
     client._ap_storage.get = AsyncMock()
     client._ap_storage.aset = AsyncMock()
+    client.is_local = lambda jid_: SatXMPPComponent.is_local(client, jid_)
     return client