From 954a1b37945cc3f30ff23ae67d34d1d8f9ef6dae Mon Sep 17 00:00:00 2001 From: Lukas Hellebrandt Date: Wed, 11 Dec 2024 14:01:54 +0100 Subject: [PATCH] Only the second call should raise an exception --- tests/foreman/destructive/test_ldap_authentication.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/foreman/destructive/test_ldap_authentication.py b/tests/foreman/destructive/test_ldap_authentication.py index 7ca70ce2089..fbef0327999 100644 --- a/tests/foreman/destructive/test_ldap_authentication.py +++ b/tests/foreman/destructive/test_ldap_authentication.py @@ -428,8 +428,7 @@ def test_login_failure_rhsso_user_if_internal_user_exist( 'password': settings.rhsso.rhsso_password, } with module_target_sat.ui_session(login=False) as rhsso_session: - with pytest.raises(NavigationTriesExceeded) as error: - rhsso_session.rhsso_login.login(login_details) + rhsso_session.rhsso_login.login(login_details) with pytest.raises(NavigationTriesExceeded) as error: rhsso_session.task.read_all() assert error.typename == 'NavigationTriesExceeded'