diff --git a/testsuite/model/test-all-profiles.sh b/testsuite/model/test-all-profiles.sh index 532183816a..0e2a2536a4 100755 --- a/testsuite/model/test-all-profiles.sh +++ b/testsuite/model/test-all-profiles.sh @@ -15,9 +15,10 @@ for I in `perl -ne 'print "$1\n" if (m,([^<]+),)' pom.xml`; do echo "========" echo "======== Profile $I" echo "========" - mvn -B test "-P$I" "$@" - EXIT_CODE=$[$EXIT_CODE + $?] + mvn -B -Dsurefire.timeout=600 test "-P$I" "$@" 2>&1 | tee /tmp/surefire.out + EXIT_CODE=$[$EXIT_CODE + ${PIPESTATUS[0]}] mv target/surefire-reports "target/surefire-reports-$I" + perl -ne "print '::error::| $I | Timed out.' . \"\n\" if (/There was a timeout in the fork/)" /tmp/surefire.out done ## If the jacoco file is present, generate reports in each of the model projects