if test $? != 0 ; then
echo "comparison failed - modrdn operations did not complete correctly"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
+ exit -1
fi
if test $? != 0 ; then
echo "comparison failed - modrdn operations did not complete correctly"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
+ exit -1
fi
# Ensure that you cannot find the entry for which the rdn was deleted as
if test $? != 0 ; then
echo "failure: ldapsearch found attribute that was to be removed!"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
+ exit -1
fi
echo "Using ldapsearch to retrieve all the entries..."
if test $? != 0 ; then
echo "comparison failed - modrdn operations did not complete correctly"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
+ exit -1
fi
# Test that you can use modrdn with an attribute value which was previously
if test $? != 0 ; then
echo "comparison failed - modrdn operations did not complete correctly"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
+ exit -1
fi
echo "Testing modrdn with newSuperior as child of target "
'cn=James A Jones 1, ou=Alumni Association, ou=People, dc=example, dc=com' 'cn=James A Jones 1'
RC=$?
-if test $RC -eq 0 ; then
+case $RC in
+0)
echo "ldapmodrdn succeeded, should have failed!"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
- exit 1
-fi
+ exit -1
+ ;;
+32)
+ echo "ldapmodrdn failed (noSuchObject)"
+ ;;
+*)
+ echo "ldapmodrdn failed ($RC)!"
+ test $KILLSERVERS != no && kill -HUP $KILLPIDS
+ exit $RC
+ ;;
+esac
test $KILLSERVERS != no && kill -HUP $KILLPIDS