diff --git a/tests/test_connection.py b/tests/test_connection.py index db60384..c92e088 100644 --- a/tests/test_connection.py +++ b/tests/test_connection.py @@ -1,5 +1,7 @@ """Connection test module.""" +from inspect import signature + import pytest from keycloak.connection import ConnectionManager @@ -65,3 +67,6 @@ def test_counter_part(): for method in sync_methods: async_method = method[2:] assert (async_method in con_methods) is True + sync_sign = signature(getattr(ConnectionManager, method)) + async_sign = signature(getattr(ConnectionManager, async_method)) + assert sync_sign.parameters == async_sign.parameters diff --git a/tests/test_keycloak_admin.py b/tests/test_keycloak_admin.py index 0f4eb57..d7c8bc4 100644 --- a/tests/test_keycloak_admin.py +++ b/tests/test_keycloak_admin.py @@ -3,6 +3,7 @@ import copy import os import uuid +from inspect import signature from typing import Tuple import freezegun @@ -6160,3 +6161,6 @@ def test_counter_part(): for method in sync_methods: async_method = f"a_{method}" assert (async_method in admin_methods) is True + sync_sign = signature(getattr(KeycloakAdmin, method)) + async_sign = signature(getattr(KeycloakAdmin, async_method)) + assert sync_sign.parameters == async_sign.parameters diff --git a/tests/test_keycloak_openid.py b/tests/test_keycloak_openid.py index f05fbd7..56d0885 100644 --- a/tests/test_keycloak_openid.py +++ b/tests/test_keycloak_openid.py @@ -1,5 +1,6 @@ """Test module for KeycloakOpenID.""" +from inspect import signature from typing import Tuple from unittest import mock @@ -987,3 +988,6 @@ def test_counter_part(): for method in sync_methods: async_method = f"a_{method}" assert (async_method in openid_methods) is True + sync_sign = signature(getattr(KeycloakOpenID, method)) + async_sign = signature(getattr(KeycloakOpenID, async_method)) + assert sync_sign.parameters == async_sign.parameters diff --git a/tests/test_keycloak_uma.py b/tests/test_keycloak_uma.py index 13e49ad..462b7cb 100644 --- a/tests/test_keycloak_uma.py +++ b/tests/test_keycloak_uma.py @@ -1,6 +1,7 @@ """Test module for KeycloakUMA.""" import re +from inspect import signature import pytest @@ -613,3 +614,6 @@ def test_counter_part(): for method in sync_methods: async_method = f"a_{method}" assert (async_method in uma_methods) is True + sync_sign = signature(getattr(KeycloakUMA, method)) + async_sign = signature(getattr(KeycloakUMA, async_method)) + assert sync_sign.parameters == async_sign.parameters