Test suite for bug #39554: Feature request: line buffered output.

This commit is contained in:
Ole Tange 2013-07-30 23:15:40 +02:00
parent 88540d06a7
commit df204a69fa
2 changed files with 30 additions and 5 deletions

View file

@ -2,12 +2,21 @@
rm -rf tmp 2>/dev/null
cp -a input-files/testdir2 tmp
cd tmp
echo '### Test filenames containing UTF-8'
find . -name '*.jpg' | parallel -j +0 convert -geometry 120 {} {//}/thumb_{/}
cat <<'EOF' | sed -e 's/;$/; /;s/$SERVER1/'$SERVER1'/;s/$SERVER2/'$SERVER2'/' | stdout parallel -j0 -k -L1
echo '### Test filenames containing UTF-8';
cd tmp;
find . -name '*.jpg' | parallel -j +0 convert -geometry 120 {} {//}/thumb_{/};
find |grep -v CVS | sort;
find |grep -v CVS | sort
echo '### bug #39554: Feature request: line buffered output';
parallel -j0 --linebuffer 'echo -n start {};sleep 0.{#};echo middle -n {};sleep 1.{#}5;echo next to last {};sleep 1.{#};echo -n last {}' ::: A B C
echo
echo '### bug #39554: Feature request: line buffered output --tag';
parallel --tag -j0 --linebuffer 'echo -n start {};sleep 0.{#};echo middle -n {};sleep 1.{#}5;echo next to last {};sleep 1.{#};echo -n last {}' ::: A B C
echo
EOF
cd ..
rm -rf tmp

View file

@ -12,3 +12,19 @@
./中国 (Zhōngguó)
./中国 (Zhōngguó)/China's (中国) road.jpg
./中国 (Zhōngguó)/thumb_China's (中国) road.jpg
### bug #39554: Feature request: line buffered output
start Amiddle -n A
start Bmiddle -n B
start Cmiddle -n C
next to last A
next to last B
next to last C
last Alast Blast C
### bug #39554: Feature request: line buffered output --tag
A start Amiddle -n A
B start Bmiddle -n B
C start Cmiddle -n C
A next to last A
B next to last B
C next to last C
A last AB last BC last C