From bf8eaf1f1ead508635470cae42da535d7bed5efc Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Tue, 29 Jun 1999 01:17:58 +0000 Subject: [PATCH] ldapmodify/add: Fix -P option tests: use "ldapadd" instead of "ldapmodify -a" --- clients/tools/ldapmodify.c | 2 +- tests/scripts/defines.sh | 2 -- tests/scripts/test002-populate | 6 +++--- tests/scripts/test007-replication | 6 +++--- 4 files changed, 7 insertions(+), 9 deletions(-) diff --git a/clients/tools/ldapmodify.c b/clients/tools/ldapmodify.c index a08ff51667..ebb9173019 100644 --- a/clients/tools/ldapmodify.c +++ b/clients/tools/ldapmodify.c @@ -116,7 +116,7 @@ main( int argc, char **argv ) authmethod = LDAP_AUTH_SIMPLE; version = -1; - while (( i = getopt( argc, argv, "WFabckKnrtvh:p:D:w:d:f:" )) != EOF ) { + while (( i = getopt( argc, argv, "WFabckKnrtvh:p:D:w:d:f:P:" )) != EOF ) { switch( i ) { case 'a': /* add */ new = 1; diff --git a/tests/scripts/defines.sh b/tests/scripts/defines.sh index 695c2903f8..736d3ad75d 100755 --- a/tests/scripts/defines.sh +++ b/tests/scripts/defines.sh @@ -19,8 +19,6 @@ fi if test "$LDAP_PROTO" ; then PROTO="-P $LDAP_PROTO" -else - PROTO="" fi PASSWDCONF=$DATADIR/slapd-passwd.conf diff --git a/tests/scripts/test002-populate b/tests/scripts/test002-populate index 641a3d5c65..80a0479a6f 100755 --- a/tests/scripts/test002-populate +++ b/tests/scripts/test002-populate @@ -31,12 +31,12 @@ for i in 0 1 2 3 4 5; do fi done -echo "Using ldapmodify to populate the database..." -$LDAPMODIFY -a -D "$MANAGERDN" -h localhost -p $PORT -w $PASSWD < \ +echo "Using ldapadd to populate the database..." +$LDAPADD -D "$MANAGERDN" -h localhost -p $PORT -w $PASSWD < \ $LDIFORDERED > /dev/null 2>&1 RC=$? if test $RC != 0 ; then - echo "ldapmodify failed!" + echo "ldapadd failed!" kill -HUP $PID exit $RC fi diff --git a/tests/scripts/test007-replication b/tests/scripts/test007-replication index b3d71c295c..8a79f7d3e0 100755 --- a/tests/scripts/test007-replication +++ b/tests/scripts/test007-replication @@ -67,12 +67,12 @@ echo "Starting slurpd..." $SLURPD -f $MASTERCONF -d 4 -t $REPLDIR > $SLURPLOG 2>&1 & SLURPPID=$! -echo "Using ldapmodify to populate the database..." -$LDAPMODIFY -a -D "$MANAGERDN" -h localhost -p $PORT -w $PASSWD < \ +echo "Using ldapadd to populate the database..." +$LDAPADD -D "$MANAGERDN" -h localhost -p $PORT -w $PASSWD < \ $LDIFORDERED > /dev/null 2>&1 RC=$? if test $RC != 0 ; then - echo "ldapmodify failed!" + echo "ldapadd failed!" kill -HUP $PID $SLAVEPID $SLURPPID exit $RC fi -- 2.39.5