Skip to content

Commit

Permalink
Merge pull request #210 from bitshares/fix-parallel-tests
Browse files Browse the repository at this point in the history
Fix run-parallel-tests for chain_test in core
  • Loading branch information
abitmore authored Sep 24, 2020
2 parents 5abdd34 + e20a3f4 commit 781c9cd
Showing 1 changed file with 17 additions and 13 deletions.
30 changes: 17 additions & 13 deletions tests/run-parallel-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,27 @@ if [ "$BOOST_VERSION" = "" -o "$BOOST_VERSION" -lt 105900 ]; then
echo "Boost version '$BOOST_VERSION' - executing tests serially"
"$@"
else
echo "=== $1 list_content test begin ==="
"$1" --list_content 2>&1 \
| grep '\*$' \
| sed 's=\*$==;s=^ =/=' \
| while read t; do
case "$t" in
/*) echo "$pre$t"; ;;
*) echo "$t"; ;;
esac
done
| sed 's=\*$==;s=^ =/='
echo "=== $1 list_content test end ==="
"$1" --list_content 2>&1 \
| grep '\*$' \
| sed 's=\*$==;s=^ =/=' \
| while read t; do
case "$t" in
/*) echo "$pre$t"; ;;
*) echo "$t"; ;;
esac
done \
| (while read t; do
case "$t" in
/*) echo "$pre$t"; found=1; ;;
*) if [ -n "$pre" -a "$found" = "0" ]; then
echo "$pre"
fi
pre="$t"
found=0
;;
esac
done
if [ -n "$pre" -a "$found" = "0" ]; then
echo "$pre"
fi) \
| parallel echo Running {}\; "$@" -t {}
fi

0 comments on commit 781c9cd

Please sign in to comment.