summaryrefslogtreecommitdiff
path: root/testprogs
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2007-11-05 02:29:17 +0100
committerStefan Metzmacher <metze@samba.org>2007-12-21 05:44:15 +0100
commitc112597ba794bfd24c1f56de7ba14bec4a70f38e (patch)
tree9480cc896cc3bad78fa51ddeecc0b5372e5bcb2b /testprogs
parentdda00fedd4df2353b171a9594efafa335b15230b (diff)
downloadsamba-c112597ba794bfd24c1f56de7ba14bec4a70f38e.tar.gz
samba-c112597ba794bfd24c1f56de7ba14bec4a70f38e.tar.bz2
samba-c112597ba794bfd24c1f56de7ba14bec4a70f38e.zip
r25826: Prove that adding a user or computer via LDAP doesn't magicly give
them any more group memberships. Andrew Bartlett (This used to be commit c805934017af2c983b31738cb888103a5f972fdc)
Diffstat (limited to 'testprogs')
-rwxr-xr-xtestprogs/ejs/ldap.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/testprogs/ejs/ldap.js b/testprogs/ejs/ldap.js
index 8376b15fbb..56fbf4f0df 100755
--- a/testprogs/ejs/ldap.js
+++ b/testprogs/ejs/ldap.js
@@ -432,6 +432,8 @@ objectClass: user
assert(res.msgs[0].objectCategory == ("CN=Person,CN=Schema,CN=Configuration," + base_dn));
assert(res.msgs[0].sAMAccountType == 805306368);
// assert(res[0].userAccountControl == 546);
+ assert(res.msgs[0].memberOf[0] == ("CN=ldaptestgroup2,CN=Users," + base_dn));
+ assert(res.msgs[0].memberOf.length == 1);
println("Testing ldb.search for (&(cn=ldaptestuser)(objectCategory=cn=person,cn=schema,cn=configuration," + base_dn + "))");
var res2 = ldb.search("(&(cn=ldaptestuser)(objectCategory=cn=person,cn=schema,cn=configuration," + base_dn + "))");
@@ -510,6 +512,7 @@ objectClass: user
// assert(res.msgs[0].sAMAccountType == 805306368);
// assert(res.msgs[0].userAccountControl == 546);
assert(res.msgs[0].memberOf[0] == ("CN=ldaptestgroup2,CN=Users," + base_dn));
+ assert(res.msgs[0].memberOf.length == 1);
println("Testing ldb.search for (&(cn=ldaptestcomputer)(objectCategory=cn=computer,cn=schema,cn=configuration," + base_dn + "))");
var res2 = ldb.search("(&(cn=ldaptestcomputer)(objectCategory=cn=computer,cn=schema,cn=configuration," + base_dn + "))");