1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-03 13:47:25 +03:00

selftest: Fix flapping samba.dsdb test

The check for the final digit in the SID was wrong, any domain SID
ending with a zero would fail the test.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
This commit is contained in:
Andrew Bartlett 2017-12-13 14:46:00 +13:00
parent dfc4670640
commit d2b14b7578

View File

@ -207,7 +207,7 @@ class DsdbTests(TestCase):
# i.e a SID not in the current domain.
#
dom_sid = self.samdb.get_domain_sid()
if str(dom_sid)[:-1] == "0":
if str(dom_sid).endswith("0"):
c = "9"
else:
c = "0"