mirror of
https://git.savannah.gnu.org/git/parallel.git
synced 2024-12-23 05:07:54 +00:00
testsuite: mop removed. Works better on heavy loaded machine.
This commit is contained in:
parent
594ca7576a
commit
b6a729c5f7
|
@ -7,14 +7,12 @@ local: ../src/parallel tests-to-run/*local* wanted-results/*local* prereqlocal
|
|||
date
|
||||
|
||||
prereqlocal: installparallel
|
||||
echo | mop || (echo mop is required for testsuite; /bin/false)
|
||||
seq 1 2 | mop || (echo seq is required for testsuite; /bin/false)
|
||||
seq 1 2 >/dev/null || (echo seq is required for testsuite; /bin/false)
|
||||
stdout echo || (echo stdout is required for testsuite; /bin/false)
|
||||
convert | mop || (echo convert is required for testsuite; /bin/false)
|
||||
ren 2>&1 | mop || (echo ren is required for testsuite; /bin/false)
|
||||
echo | buffer | mop || (echo buffer is required for testsuite; /bin/false)
|
||||
echo 1+2 | bc | mop || (echo bc is required for testsuite; /bin/false)
|
||||
stdout gawk | mop || (echo gawk is required for testsuite; /bin/false)
|
||||
convert >/dev/null || (echo convert is required for testsuite; /bin/false)
|
||||
ren '$$_' a || (echo ren is required for testsuite; /bin/false)
|
||||
echo 1+2 | bc >/dev/null || (echo bc is required for testsuite; /bin/false)
|
||||
echo | gawk '{print "gawk is installed"}' || (echo gawk is required for testsuite; /bin/false)
|
||||
expect -c 'spawn cat; puts "expect is installed"' || (echo expect is required for testsuite; /bin/false)
|
||||
echo | pv -qL 10 || (echo pv is required for testsuite; /bin/false)
|
||||
echo | script -c echo -q /dev/null || (echo script is required for testsuite; /bin/false)
|
||||
|
|
|
@ -1,50 +1,50 @@
|
|||
#!/bin/bash
|
||||
|
||||
cat <<'EOF' | sed -e 's/;$/; /;s/$SERVER1/'$SERVER1'/;s/$SERVER2/'$SERVER2'/' | stdout parallel -j0 -k -L1
|
||||
echo "### Test -I"
|
||||
echo "### Test -I";
|
||||
seq 1 10 | parallel -k 'seq 1 {} | parallel -k -I :: echo {} ::'
|
||||
|
||||
echo "### Test -X -I"
|
||||
echo "### Test -X -I";
|
||||
seq 1 10 | parallel -k 'seq 1 {} | parallel -j1 -X -k -I :: echo a{} b::'
|
||||
|
||||
echo "### Test -m -I"
|
||||
echo "### Test -m -I";
|
||||
seq 1 10 | parallel -k 'seq 1 {} | parallel -j1 -m -k -I :: echo a{} b::'
|
||||
|
||||
echo "### Test max line length -m -I"
|
||||
echo "### Test max line length -m -I";
|
||||
seq 1 60000 | parallel -I :: -m -j1 echo a::b::c |
|
||||
mop -q "|sort |md5sum" :par1;
|
||||
export CHAR=$(cat ~/.mop/:par1 | wc -c);
|
||||
export LINES=$(cat ~/.mop/:par1 | wc -l);
|
||||
echo -n "Chars per line ($CHAR/$LINES): ";
|
||||
echo "$CHAR/$LINES" | bc
|
||||
tee >(sort |md5sum) >/tmp/114-a$$;
|
||||
export CHAR=$(cat /tmp/114-a$$ | wc -c);
|
||||
export LINES=$(cat /tmp/114-a$$ | wc -l);
|
||||
echo "Chars per line ($CHAR/$LINES): "$(echo "$CHAR/$LINES" | bc);
|
||||
rm /tmp/114-a$$
|
||||
|
||||
echo "### Test max line length -X -I"
|
||||
echo "### Test max line length -X -I";
|
||||
seq 1 60000 | parallel -I :: -X -j1 echo a::b::c |
|
||||
mop -q "|sort |md5sum" :par;
|
||||
export CHAR=$(cat ~/.mop/:par | wc -c);
|
||||
export LINES=$(cat ~/.mop/:par | wc -l);
|
||||
echo -n "Chars per line ($CHAR/$LINES): ";
|
||||
echo "$CHAR/$LINES" | bc
|
||||
tee >(sort |md5sum) >/tmp/114-b$$;
|
||||
export CHAR=$(cat /tmp/114-b$$ | wc -c);
|
||||
export LINES=$(cat /tmp/114-b$$ | wc -l);
|
||||
echo "Chars per line ($CHAR/$LINES): "$(echo "$CHAR/$LINES" | bc);
|
||||
rm /tmp/114-b$$
|
||||
|
||||
echo "### bug #36659: --sshlogin strips leading slash from ssh command"
|
||||
echo "### bug #36659: --sshlogin strips leading slash from ssh command";
|
||||
parallel --sshlogin '/usr/bin/ssh localhost' echo ::: OK
|
||||
|
||||
echo "### bug #36660: --workdir mkdir does not use --sshlogin custom ssh"
|
||||
echo "### bug #36660: --workdir mkdir does not use --sshlogin custom ssh";
|
||||
cd /tmp; echo OK > parallel_test.txt;
|
||||
ssh () { echo Failed; };
|
||||
export -f ssh;
|
||||
parallel --workdir /tmp/foo/bar --transfer --sshlogin '/usr/bin/ssh localhost' cat ::: parallel_test.txt;
|
||||
|
||||
echo "bug #36657: --load does not work with custom ssh"
|
||||
echo "bug #36657: --load does not work with custom ssh";
|
||||
cd /tmp; echo OK > parallel_test.txt;
|
||||
ssh () { echo Failed; };
|
||||
export -f ssh;
|
||||
parallel --load=1000% -S "/usr/bin/ssh localhost" echo ::: OK
|
||||
|
||||
echo "bug #34958: --pipe with record size measured in lines"
|
||||
echo "bug #34958: --pipe with record size measured in lines";
|
||||
seq 10 | parallel --pipe -L 4 cat\;echo FOO
|
||||
|
||||
echo "bug #34958: --pipe with record size measured in lines"
|
||||
echo "bug #34958: --pipe with record size measured in lines";
|
||||
seq 10 | parallel --pipe -l 4 cat\;echo FOO
|
||||
|
||||
EOF
|
||||
|
|
|
@ -37,10 +37,19 @@ echo '### Test -m'
|
|||
(echo foo;echo bar;echo joe.gif) | parallel -j1 -kX echo 1{}2{.}3 A{.}B{.}C
|
||||
seq 1 6 | parallel -k printf '{}.gif\\n' | parallel -j1 -km echo a{}b{.}c{.}
|
||||
seq 1 6 | parallel -k printf '{}.gif\\n' | parallel -j1 -kX echo a{}b{.}c{.}
|
||||
echo '### Test -m with 60000 args'
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' | parallel -j1 -km echo a{}b{.}c{.} | mop -d 4 "|md5sum" "| wc"
|
||||
echo '### Test -X with 60000 args'
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' | parallel -j1 -kX echo a{}b{.}c{.} | mop -d 4 "|md5sum" "| wc"
|
||||
|
||||
echo '### Test -m with 60000 args';
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' |
|
||||
parallel -j1 -km echo a{}b{.}c{.} |
|
||||
tee >(wc) >(md5sum) >/dev/null;
|
||||
wait
|
||||
|
||||
echo '### Test -X with 60000 args';
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' |
|
||||
parallel -j1 -kX echo a{}b{.}c{.} |
|
||||
tee >(wc) >(md5sum) >/dev/null;
|
||||
wait
|
||||
|
||||
echo '### Test -X with 60000 args and 5 expansions'
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' | parallel -j1 -kX echo a{}b{.}c{.}{.}{} | wc -l
|
||||
seq 1 60000 | perl -pe 's/$/.gif\n/' | parallel -j1 -kX echo a{}b{.}c{.}{.} | wc -l
|
||||
|
|
|
@ -102,8 +102,8 @@ echo '### Test of -j filename - non-existent file';
|
|||
|
||||
echo '### Test of -j filename';
|
||||
echo 3 >/tmp/jobs_to_run1;
|
||||
parallel -j /tmp/jobs_to_run1 -v sleep 0.{} ::: 9 7 5 3 1;
|
||||
# Should give 0.5 0.7 0.9 0.1 0.3
|
||||
parallel -j /tmp/jobs_to_run1 -v sleep {} ::: 10 8 6 5 4;
|
||||
# Should give 6 8 10 5 4
|
||||
|
||||
echo '### Test ::::'
|
||||
echo '### Change --arg-file-sep'
|
||||
|
@ -216,4 +216,4 @@ EOF
|
|||
echo '### Test of -j filename with file content changing';
|
||||
echo 1 >/tmp/jobs_to_run2;
|
||||
(sleep 3; echo 10 >/tmp/jobs_to_run2) &
|
||||
parallel -j /tmp/jobs_to_run2 -v sleep {} ::: 3.3 1.1 1.3 1.4 1.2 1 1 1 1 1 1 1 1 1 1 1
|
||||
parallel -j /tmp/jobs_to_run2 -v sleep {} ::: 3.3 1.21 1.43 1.54 1.32 1 1 1 1 1 1 1 1 1 1 1
|
||||
|
|
|
@ -88,11 +88,11 @@ O. Tange (2011): GNU Parallel - The Command-Line Power Tool,
|
|||
;login: The USENIX Magazine, February 2011:42-47.
|
||||
parallel: Error: Parsing of --jobs/-j/--max-procs/-P failed.
|
||||
### Test of -j filename
|
||||
sleep 0.5
|
||||
sleep 0.7
|
||||
sleep 0.9
|
||||
sleep 0.1
|
||||
sleep 0.3
|
||||
sleep 6
|
||||
sleep 8
|
||||
sleep 10
|
||||
sleep 5
|
||||
sleep 4
|
||||
### Test ::::
|
||||
### Change --arg-file-sep
|
||||
1 5
|
||||
|
@ -318,10 +318,10 @@ sleep 1
|
|||
sleep 1
|
||||
sleep 1
|
||||
sleep 1
|
||||
sleep 1.1
|
||||
sleep 1.2
|
||||
sleep 1.3
|
||||
sleep 1.4
|
||||
sleep 1.21
|
||||
sleep 1.32
|
||||
sleep 1.43
|
||||
sleep 1.54
|
||||
sleep 1
|
||||
sleep 1
|
||||
sleep 1
|
||||
|
|
Loading…
Reference in a new issue