From: Andrew Bartlett Date: Thu, 1 Dec 2022 22:56:38 +0000 (+1300) Subject: s4-selftest/drs Allow re-run of DRS tests after failed cleanup X-Git-Tag: tevent-0.14.1~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3204d1350b21704474e577cb5f3f2439b673c421;p=thirdparty%2Fsamba.git s4-selftest/drs Allow re-run of DRS tests after failed cleanup Using a random base is a useful start, even if the better solution also includes a self.AddCleanup() BUG: https://bugzilla.samba.org/show_bug.cgi?id=10635 Signed-off-by: Andrew Bartlett Reviewed-by: Stefan Metzmacher --- diff --git a/source4/torture/drs/python/getnc_exop.py b/source4/torture/drs/python/getnc_exop.py index 2d58790785f..885156cc6e2 100644 --- a/source4/torture/drs/python/getnc_exop.py +++ b/source4/torture/drs/python/getnc_exop.py @@ -81,7 +81,8 @@ class DrsReplicaSyncTestCase(drs_base.DrsBaseTestCase): def setUp(self): super(DrsReplicaSyncTestCase, self).setUp() self.base_dn = self.ldb_dc1.get_default_basedn() - self.ou = "OU=test_getncchanges,%s" % self.base_dn + self.ou = "OU=test_getncchanges%d,%s" % (random.randint(0, 4294967295), + self.base_dn) self.ldb_dc1.add({ "dn": self.ou, "objectclass": "organizationalUnit"})