svn commit: samba r16072 - in branches/SAMBA_4_0/testprogs/ejs: .

abartlet at samba.org abartlet at samba.org
Wed Jun 7 04:16:02 GMT 2006


Author: abartlet
Date: 2006-06-07 04:16:02 +0000 (Wed, 07 Jun 2006)
New Revision: 16072

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=16072

Log:
Do basic wildcard searching in the ejs LDAP test.

Unfortunetly this didn't find the wildcard bug, but at least it tests
something...

Andrew Bartlett

Modified:
   branches/SAMBA_4_0/testprogs/ejs/ldap.js


Changeset:
Modified: branches/SAMBA_4_0/testprogs/ejs/ldap.js
===================================================================
--- branches/SAMBA_4_0/testprogs/ejs/ldap.js	2006-06-07 00:55:48 UTC (rev 16071)
+++ branches/SAMBA_4_0/testprogs/ejs/ldap.js	2006-06-07 04:16:02 UTC (rev 16072)
@@ -219,6 +219,33 @@
 
 	assert(res[0].dn == res3[0].dn);
 
+	println("Testing ldb.search for (&(cn=ldaptest*computer)(objectCategory=compuTER))");
+	var res4 = ldb.search("(&(cn=ldaptest*computer)(objectCategory=compuTER))");
+	if (res4.length != 1) {
+		println("Could not find (&(cn=ldaptest*computer)(objectCategory=compuTER))");
+		assert(res4.length == 1);
+	}
+
+	assert(res[0].dn == res4[0].dn);
+
+	println("Testing ldb.search for (&(cn=ldaptestcomput*)(objectCategory=compuTER))");
+	var res5 = ldb.search("(&(cn=ldaptestcomput*)(objectCategory=compuTER))");
+	if (res5.length != 1) {
+		println("Could not find (&(cn=ldaptestcomput*)(objectCategory=compuTER))");
+		assert(res5.length == 1);
+	}
+
+	assert(res[0].dn == res5[0].dn);
+
+	println("Testing ldb.search for (&(cn=*daptestcomputer)(objectCategory=compuTER))");
+	var res6 = ldb.search("(&(cn=*daptestcomputer)(objectCategory=compuTER))");
+	if (res6.length != 1) {
+		println("Could not find (&(cn=*daptestcomputer)(objectCategory=compuTER))");
+		assert(res6.length == 1);
+	}
+
+	assert(res[0].dn == res6[0].dn);
+
 	ok = ldb.del(res[0].dn);
 	if (!ok) {
 		println(ldb.errstring());



More information about the samba-cvs mailing list