mirror of
https://git.savannah.gnu.org/git/parallel.git
synced 2024-11-22 14:07:55 +00:00
69 lines
3.6 KiB
Plaintext
69 lines
3.6 KiB
Plaintext
### These tests requires VirtualBox running with the following images
|
|
tange@freebsd7
|
|
echo 'bug #40136: FreeBSD: No more processes'
|
|
bug #40136: FreeBSD: No more processes
|
|
sem --jobs 3 --id my_id -u 'echo First started; sleep 10; echo The first finished;echo' && sem --jobs 3 --id my_id -u 'echo Second started; sleep 11; echo The second finished;echo' && sem --jobs 3 --id my_id -u 'echo Third started; sleep 12; echo The third finished;echo' && sem --jobs 3 --id my_id -u 'echo Fourth started; sleep 13; echo The fourth finished;echo' && sem --wait --id my_id
|
|
First started
|
|
Second started
|
|
Third started
|
|
The first finished
|
|
|
|
Fourth started
|
|
The second finished
|
|
|
|
The third finished
|
|
|
|
The fourth finished
|
|
|
|
echo 'Test --compress --pipe'
|
|
Test --compress --pipe
|
|
jot 1000 | parallel --compress --pipe cat | wc
|
|
1000 1000 3893
|
|
echo 'bug #41613: --compress --line-buffer no newline'; perl -e 'print "It worked"'| parallel --pipe --compress --line-buffer cat; echo
|
|
bug #41613: --compress --line-buffer no newline
|
|
It worked
|
|
echo 'bug #40135: FreeBSD: sem --fg does not finish under /bin/sh'
|
|
bug #40135: FreeBSD: sem --fg does not finish under /bin/sh
|
|
sem --fg 'sleep 1; echo The job finished'
|
|
The job finished
|
|
echo 'bug #40133: FreeBSD: --round-robin gives no output'
|
|
bug #40133: FreeBSD: --round-robin gives no output
|
|
jot 1000000 | parallel --round-robin --pipe -kj3 cat | wc
|
|
1000000 1000000 6888896
|
|
jot 1000000 | parallel --round-robin --pipe -kj4 cat | wc
|
|
1000000 1000000 6888896
|
|
echo 'bug #40134: FreeBSD: --shebang not working'
|
|
bug #40134: FreeBSD: --shebang not working
|
|
(echo '#!/usr/bin/env -S parallel --shebang -rk echo'; echo It; echo worked) > shebang; chmod 755 ./shebang; ./shebang
|
|
It
|
|
worked
|
|
echo 'bug #40134: FreeBSD: --shebang(-wrap) not working'
|
|
bug #40134: FreeBSD: --shebang(-wrap) not working
|
|
(echo '#!/usr/bin/env -S parallel --shebang-wrap /usr/bin/perl :::'; echo 'print @ARGV,"\n";') > shebang-wrap; chmod 755 ./shebang-wrap; ./shebang-wrap wrap works | sort -r
|
|
wrap
|
|
works
|
|
echo 'bug #40134: FreeBSD: --shebang(-wrap) with options not working'
|
|
bug #40134: FreeBSD: --shebang(-wrap) with options not working
|
|
(echo '#!/usr/bin/env -S parallel --shebang-wrap -v -k -j 0 /usr/bin/perl -w :::'; echo 'print @ARGV,"\n";') > shebang-wrap-opt; chmod 755 ./shebang-wrap-opt; ./shebang-wrap-opt wrap works with options
|
|
/usr/bin/perl -w ./shebang-wrap-opt wrap
|
|
wrap
|
|
/usr/bin/perl -w ./shebang-wrap-opt works
|
|
works
|
|
/usr/bin/perl -w ./shebang-wrap-opt with
|
|
with
|
|
/usr/bin/perl -w ./shebang-wrap-opt options
|
|
options
|
|
bash -c 'echo bug \#43358: shellshock breaks exporting functions using --env _; echo Non-shellshock-hardened to non-shellshock-hardened; funky() { echo Function $1; }; export -f funky; PARALLEL_SHELL=bash parallel --env funky -S localhost funky ::: non-shellshock-hardened'
|
|
bug #43358: shellshock breaks exporting functions using --env _
|
|
Non-shellshock-hardened to non-shellshock-hardened
|
|
Function non-shellshock-hardened
|
|
bash -c 'echo bug \#43358: shellshock breaks exporting functions using --env _; echo Non-shellshock-hardened to shellshock-hardened; funky() { echo Function $1; }; export -f funky; parallel --env funky -S parallel@192.168.1.72 funky ::: shellshock-hardened'
|
|
bug #43358: shellshock breaks exporting functions using --env _
|
|
Non-shellshock-hardened to shellshock-hardened
|
|
Function shellshock-hardened
|
|
echo '### Test --load (must give 1=true)'
|
|
### Test --load (must give 1=true)
|
|
parallel -j0 -N0 --timeout 5 --nice 10 'bzip2 < /dev/zero >/dev/null' ::: 1 2 3 4 5 6 & parallel --argsep ,, --joblog - -N0 parallel --load 100% echo ::: 1 ,, 1 | parallel --colsep '\t' --header : echo '{=4 $_=$_>5=}'
|
|
|
|
1
|