From 70052b8b68b004de940ec93aa2751f17174e856e Mon Sep 17 00:00:00 2001 From: Ole Tange Date: Wed, 21 Nov 2012 22:32:50 +0100 Subject: [PATCH] testsuite: new tests. --- testsuite/tests-to-run/parallel-local17.sh | 5 +++ testsuite/tests-to-run/parallel-local18.sh | 48 ++++++++++++++++++++++ testsuite/tests-to-run/sem02.sh | 9 ++++ testsuite/wanted-results/parallel-local16 | 1 + testsuite/wanted-results/parallel-local17 | 1 + testsuite/wanted-results/parallel-local18 | 42 +++++++++++++++++++ testsuite/wanted-results/sem02 | 24 +++++++++++ 7 files changed, 130 insertions(+) create mode 100755 testsuite/tests-to-run/parallel-local17.sh create mode 100644 testsuite/tests-to-run/parallel-local18.sh create mode 100644 testsuite/tests-to-run/sem02.sh create mode 100644 testsuite/wanted-results/parallel-local16 create mode 100644 testsuite/wanted-results/parallel-local17 create mode 100644 testsuite/wanted-results/parallel-local18 create mode 100644 testsuite/wanted-results/sem02 diff --git a/testsuite/tests-to-run/parallel-local17.sh b/testsuite/tests-to-run/parallel-local17.sh new file mode 100755 index 00000000..6c095d3c --- /dev/null +++ b/testsuite/tests-to-run/parallel-local17.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +echo '### Test --env all chars except \n,\92,\160 - single and double --onall - no output is good' +# 92 and 160 are special for csh +perl -e 'for(1..9,9,11..91,91,93..159,159,161..255) { printf "%c%c %c%d\0",$_,$_,$_,$_ }' | stdout parallel --nice 10 -j4 -k -I // --arg-sep _ -0 V=// V2=V2=// parallel -k -j1 -S :,1/lo,1/tcsh@lo,1/csh@lo --onall --env V,V2 echo \''"{}$V$V2"'\' ::: {#} | uniq -c | grep -v ' 4 '|grep -v xauth |grep -v X11 diff --git a/testsuite/tests-to-run/parallel-local18.sh b/testsuite/tests-to-run/parallel-local18.sh new file mode 100644 index 00000000..b3de8d38 --- /dev/null +++ b/testsuite/tests-to-run/parallel-local18.sh @@ -0,0 +1,48 @@ +#!/bin/bash + +echo '### Test --env - https://savannah.gnu.org/bugs/?37351' +export TWOSPACES=' 2 spaces ' +export THREESPACES=" > My brother's 12\" records < " +echo a"$TWOSPACES"b 1 +parallel --env TWOSPACES echo 'a"$TWOSPACES"b' ::: 1 +parallel -S localhost --env TWOSPACES echo 'a"$TWOSPACES"b' ::: 1 +parallel -S csh@localhost --env TWOSPACES echo 'a"$TWOSPACES"b' ::: 1 +parallel -S tcsh@localhost --env TWOSPACES echo 'a"$TWOSPACES"b' ::: 1 + +echo a"$TWOSPACES"b a"$THREESPACES"b 2 +parallel --env TWOSPACES --env THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 2 +parallel -S localhost --env TWOSPACES --env THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 2 +parallel -S csh@localhost --env TWOSPACES --env THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 2 +parallel -S tcsh@localhost --env TWOSPACES --env THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 2 + +echo a"$TWOSPACES"b a"$THREESPACES"b 3 +parallel --env TWOSPACES,THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 3 +parallel -S localhost --env TWOSPACES,THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 3 +parallel -S csh@localhost --env TWOSPACES,THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 3 +parallel -S tcsh@localhost --env TWOSPACES,THREESPACES echo 'a"$TWOSPACES"b' 'a"$THREESPACES"b' ::: 3 + +export MIN=" \'\"" +echo a"$MIN"b 4 +parallel --env MIN echo 'a"$MIN"b' ::: 4 +parallel -S localhost --env MIN echo 'a"$MIN"b' ::: 4 +parallel -S csh@localhost --env MIN echo 'a"$MIN"b' ::: 4 +parallel -S tcsh@localhost --env MIN echo 'a"$MIN"b' ::: 4 + +export SPC="'"' * ? >o My brother's 12" records < b 2 +a 2 spaces b a > My brother's 12" records < b 2 +a 2 spaces b a > My brother's 12" records < b 2 +a 2 spaces b a > My brother's 12" records < b 2 +a 2 spaces b a > My brother's 12" records < b 2 +a 2 spaces b a > My brother's 12" records < b 3 +a 2 spaces b a > My brother's 12" records < b 3 +a 2 spaces b a > My brother's 12" records < b 3 +a 2 spaces b a > My brother's 12" records < b 3 +a 2 spaces b a > My brother's 12" records < b 3 +a \'"b 4 +a \'"b 4 +a \'"b 4 +a \'"b 4 +a \'"b 4 +a' * ? >o o o o o