From 4ee1c7c493a868ac271fd4ca19218ec9de51b88a Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Mon, 21 Feb 2011 12:48:15 +0100 Subject: s3:tests: clean up old log directories of the registry.roundtrip test --- source3/script/tests/test_net_registry_roundtrip.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'source3/script') diff --git a/source3/script/tests/test_net_registry_roundtrip.sh b/source3/script/tests/test_net_registry_roundtrip.sh index 7f13bc2f74..88919ec93c 100755 --- a/source3/script/tests/test_net_registry_roundtrip.sh +++ b/source3/script/tests/test_net_registry_roundtrip.sh @@ -44,9 +44,11 @@ conf_roundtrip_step() { # echo -n . } +LOGDIR_PREFIX="conf_roundtrip" + conf_roundtrip() { - local DIR=$(mktemp -d --tmpdir=$PREFIX conf_roundtrip_XXXX) + local DIR=$(mktemp -d --tmpdir=$PREFIX ${LOGDIR_PREFIX}_XXXX) local LOG=$DIR/log echo conf_roundtrip $1 > $LOG @@ -98,6 +100,12 @@ conf_roundtrip() CONF_FILES=${CONF_FILES:-$(find $SRCDIR/ -name '*.conf' | xargs grep -l "\[global\]")} +# remove old logs: +for OLDDIR in $(find ${PREFIX} -type d -name "${LOGDIR_PREFIX}_*") ; do + echo "removing old directory ${OLDDIR}" + rm -rf ${OLDDIR} +done + for conf_file in $CONF_FILES do testit "conf_roundtrip $conf_file" \ -- cgit