The branch, master has been updated via 7901f7c selftest: close connections after tests in samba4.ldap.rodc_rwdc.python from c5fb651 pwrap: Build libpamtest as a subsystem to avoid issues
https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit 7901f7c3baad974d3126c767cb4ef513f88564cd Author: Jamie McClymont <jamiemcclym...@catalyst.net.nz> Date: Mon Jan 8 19:18:34 2018 +1300 selftest: close connections after tests in samba4.ldap.rodc_rwdc.python This test suite had a memory impact of around 2.5GB, from built-up LDAP connection handlers under the standard process model. Signed-off-by: Jamie McClymont <jamiemcclym...@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abart...@samba.org> Reviewed-by: Garming Sam <garm...@catalyst.net.nz> Autobuild-User(master): Andrew Bartlett <abart...@samba.org> Autobuild-Date(master): Tue Jan 9 08:22:27 CET 2018 on sn-devel-144 ----------------------------------------------------------------------- Summary of changes: source4/dsdb/tests/python/password_lockout_base.py | 7 +++++++ source4/dsdb/tests/python/rodc_rwdc.py | 10 ++++++++++ 2 files changed, 17 insertions(+) Changeset truncated at 500 lines: diff --git a/source4/dsdb/tests/python/password_lockout_base.py b/source4/dsdb/tests/python/password_lockout_base.py index 992f51d..5f720ef 100644 --- a/source4/dsdb/tests/python/password_lockout_base.py +++ b/source4/dsdb/tests/python/password_lockout_base.py @@ -351,6 +351,8 @@ lockoutThreshold: """ + str(lockoutThreshold) + """ self.samr_handle = self.samr.Connect2(None, security.SEC_FLAG_MAXIMUM_ALLOWED) self.samr_domain = self.samr.OpenDomain(self.samr_handle, security.SEC_FLAG_MAXIMUM_ALLOWED, self.domain_sid) + self.addCleanup(self.delete_ldb_connections) + # (Re)adds the test user accounts self.lockout1krb5_creds = self.insta_creds(self.template_creds, username="lockout1krb5", @@ -363,6 +365,11 @@ lockoutThreshold: """ + str(lockoutThreshold) + """ kerberos_state=DONT_USE_KERBEROS) self.lockout1ntlm_ldb = self._readd_user(self.lockout1ntlm_creds) + def delete_ldb_connections(self): + del self.lockout1krb5_ldb + del self.lockout1ntlm_ldb + del self.ldb + def tearDown(self): super(BasePasswordTestCase, self).tearDown() diff --git a/source4/dsdb/tests/python/rodc_rwdc.py b/source4/dsdb/tests/python/rodc_rwdc.py index 371ff74..8c6dd4c 100644 --- a/source4/dsdb/tests/python/rodc_rwdc.py +++ b/source4/dsdb/tests/python/rodc_rwdc.py @@ -224,6 +224,11 @@ class RodcRwdcCachedTests(password_lockout_base.BasePasswordTestCase): # make sure DCs are synchronized before the test self.force_replication() + def delete_ldb_connections(self): + super(RodcRwdcCachedTests, self).delete_ldb_connections() + del self.rwdc_db + del self.rodc_db + def test_cache_and_flush_password(self): username = self.lockout1krb5_creds.get_username() userpass = self.lockout1krb5_creds.get_password() @@ -767,6 +772,11 @@ class RodcRwdcTests(password_lockout_base.BasePasswordTestCase): self.rwdc_dn = get_server_ref_from_samdb(self.rwdc_db) self.rodc_dn = get_server_ref_from_samdb(self.rodc_db) + def delete_ldb_connections(self): + super(RodcRwdcTests, self).delete_ldb_connections() + del self.rwdc_db + del self.rodc_db + def assertReferral(self, fn, *args, **kwargs): try: fn(*args, **kwargs) -- Samba Shared Repository