]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
Update test044 to catch ITS#8923
authorQuanah Gibson-Mount <quanah@openldap.org>
Wed, 3 Oct 2018 20:28:54 +0000 (20:28 +0000)
committerQuanah Gibson-Mount <quanah@openldap.org>
Wed, 3 Oct 2018 22:23:27 +0000 (22:23 +0000)
tests/scripts/defines.sh
tests/scripts/test044-dynlist

index 97cf08fd7f89fe7dcf5be8c6a8ac95ae5f6675f3..7d6202357b9ba633d8412b80b875d09fd34b96c6 100755 (executable)
@@ -261,6 +261,7 @@ UPDATEDN="cn=Replica,$BASEDN"
 PASSWD=secret
 BABSDN="cn=Barbara Jensen,ou=Information Technology DivisioN,ou=People,$BASEDN"
 BJORNSDN="cn=Bjorn Jensen,ou=Information Technology DivisioN,ou=People,$BASEDN"
+BADBJORNSDN="cn=Bjorn JensenNotReally,ou=Information Technology DivisioN,ou=People,$BASEDN"
 JAJDN="cn=James A Jones 1,ou=Alumni Association,ou=People,$BASEDN"
 JOHNDDN="cn=John Doe,ou=Information Technology Division,ou=People,$BASEDN"
 MELLIOTDN="cn=Mark Elliot,ou=Alumni Association,ou=People,$BASEDN"
index 08678bf42453dccd11398b4809ec22b079ce38f9..e5a0c47dc5348b7e559c55af44f1e2d543e7ad58 100755 (executable)
@@ -468,6 +468,35 @@ case $RC in
 esac
 echo "" >> $SEARCHOUT
 
+CMPDN="$BADBJORNSDN"
+echo "Testing list compare (should return FALSE)..."
+echo "# Testing list compare... (should return FALSE)" >> $SEARCHOUT
+$LDAPCOMPARE -h $LOCALHOST -p $PORT1 \
+       "cn=Dynamic List of Members,$LISTDN" "member:$CMPDN" \
+       >> $SEARCHOUT 2>&1
+RC=$?
+case $RC in
+5)
+       echo "ldapcompare returned FALSE ($RC)!"
+       test $KILLSERVERS != no && kill -HUP $KILLPIDS
+       exit $RC
+       ;;
+6)
+       echo "ldapcompare returned TRUE ($RC)"
+       ;;
+0)
+       echo "ldapcompare returned success ($RC)!"
+       test $KILLSERVERS != no && kill -HUP $KILLPIDS
+       exit -1
+       ;;
+*)
+       echo "ldapcompare failed ($RC)!"
+       test $KILLSERVERS != no && kill -HUP $KILLPIDS
+       exit $RC
+       ;;
+esac
+echo "" >> $SEARCHOUT
+
 echo "Testing list compare (should return FALSE)..."
 echo "# Testing list compare (should return FALSE)..." >> $SEARCHOUT
 $LDAPCOMPARE -h $LOCALHOST -p $PORT1 \