admins/ldapauth: attempt to fix tests, root auth gets broken during slapd restart test

This commit is contained in:
Alexandre Aubin 2022-09-30 19:31:04 +02:00
parent 2199d60732
commit 87447def38
2 changed files with 2 additions and 2 deletions

View file

@ -78,7 +78,7 @@ def test_authenticate_server_down(mocker):
def test_authenticate_change_password(): def test_authenticate_change_password():
LDAPAuth().authenticate_credentials(credentials="yunohost") LDAPAuth().authenticate_credentials(credentials="alice:Yunohost")
tools_rootpw("plopette", check_strength=False) tools_rootpw("plopette", check_strength=False)

View file

@ -84,7 +84,7 @@ class LDAPInterface:
def connect(self): def connect(self):
def _reconnect(): def _reconnect():
con = ldap.ldapobject.ReconnectLDAPObject( con = ldap.ldapobject.ReconnectLDAPObject(
self.uri, retry_max=10, retry_delay=0.5 self.uri, retry_max=10, retry_delay=2
) )
con.sasl_non_interactive_bind_s("EXTERNAL") con.sasl_non_interactive_bind_s("EXTERNAL")
return con return con