run-test.sh: use the POSIX '-L 1' for xargs

This allows tests to be run on platforms where '-l'
isn't implemented, like MacOS.
This commit is contained in:
Jeff Rizzo 2021-01-21 12:05:30 -08:00 committed by Pete Johanson
parent 5eeb310b2f
commit c0cab57c2d

View file

@ -17,7 +17,7 @@ testcases=$(find $path -name native_posix.keymap -exec dirname \{\} \;)
num_cases=$(echo "$testcases" | wc -l) num_cases=$(echo "$testcases" | wc -l)
if [ $num_cases -gt 1 ]; then if [ $num_cases -gt 1 ]; then
echo "" > ./build/tests/pass-fail.log echo "" > ./build/tests/pass-fail.log
echo "$testcases" | xargs -l -P 4 ./run-test.sh echo "$testcases" | xargs -L 1 -P 4 ./run-test.sh
err=$? err=$?
sort -k2 ./build/tests/pass-fail.log sort -k2 ./build/tests/pass-fail.log
exit $err exit $err
@ -45,4 +45,4 @@ else
echo "PASS: $testcase" >> ./build/tests/pass-fail.log echo "PASS: $testcase" >> ./build/tests/pass-fail.log
exit 0 exit 0
fi fi
fi fi