From: Simo Sorce Date: Wed, 24 Sep 2008 05:34:10 +0000 (-0400) Subject: Fix python test, we can't check only the first member, because the order X-Git-Tag: samba-4.0.0alpha6~769^2~231^2~1^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7b20cbb1152af7f3779cbb0dd74d939d8f1637c0;p=thirdparty%2Fsamba.git Fix python test, we can't check only the first member, because the order is not guaranteed --- diff --git a/source4/lib/ldb/tests/python/ldap.py b/source4/lib/ldb/tests/python/ldap.py index bc6f80e856d..6c910b63f1b 100755 --- a/source4/lib/ldb/tests/python/ldap.py +++ b/source4/lib/ldb/tests/python/ldap.py @@ -781,7 +781,10 @@ member: cn=ldaptestuser4,cn=ldaptestcontainer,""" + self.base_dn + """ self.assertTrue("objectGuid" not in res[0]) self.assertTrue("whenCreated" in res[0]) self.assertTrue("nTSecurityDescriptor" in res[0]) - self.assertEquals(res[0]["member"][0].upper(), ("CN=ldaptestuser2,CN=Users," + self.base_dn).upper()) + memberUP = [] + for m in res[0]["member"]: + memberUP.append(m.upper()) + self.assertTrue(("CN=ldaptestuser2,CN=Users," + self.base_dn).upper() in memberUP) ldb.modify_ldif(""" dn: cn=ldaptestgroup2,cn=users,""" + self.base_dn + """