Parcourir la source

allow msgtest to be used with only one parameter

David Kalnischkies il y a 14 ans
Parent
commit
d73840dc51
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      test/integration/framework

+ 2 - 1
test/integration/framework

@@ -29,7 +29,8 @@ msgtest() {
 	while [ -n "$1" ]; do
 	while [ -n "$1" ]; do
 		echo -n "${CINFO}$1${CCMD} " >&2;
 		echo -n "${CINFO}$1${CCMD} " >&2;
 		echo -n "$(echo "$2" | sed -e 's/^aptc/apt-c/' -e 's/^aptg/apt-g/' -e 's/^aptf/apt-f/')${CINFO} " >&2;
 		echo -n "$(echo "$2" | sed -e 's/^aptc/apt-c/' -e 's/^aptg/apt-g/' -e 's/^aptf/apt-f/')${CINFO} " >&2;
-		shift 2
+		shift
+		if [ -n "$1" ]; then shift; else break; fi
 	done
 	done
 	echo -n "…${CNORMAL} " >&2;
 	echo -n "…${CNORMAL} " >&2;
 }
 }