diff --git a/hadoop-ozone/dev-support/checks/_mvn_unit_report.sh b/hadoop-ozone/dev-support/checks/_mvn_unit_report.sh index 0249c7a498d..8b7ed939b27 100755 --- a/hadoop-ozone/dev-support/checks/_mvn_unit_report.sh +++ b/hadoop-ozone/dev-support/checks/_mvn_unit_report.sh @@ -63,6 +63,7 @@ grep -A1 'Crashed tests' "${REPORT_DIR}/output.log" \ cat "${crashes}" >> "${tempfile}" # Check for tests that started but were not finished +timeouts=${REPORT_DIR}/timeouts.txt if grep -q 'There was a timeout.*in the fork' "${REPORT_DIR}/output.log"; then diff -uw \ <(grep -e 'Running org' "${REPORT_DIR}/output.log" \ @@ -75,7 +76,8 @@ if grep -q 'There was a timeout.*in the fork' "${REPORT_DIR}/output.log"; then | sort -u -k2) \ | grep '^- ' \ | awk '{ print $3 }' \ - >> "${tempfile}" + > "${timeouts}" + cat "${timeouts}" >> "${tempfile}" fi sort -u "${tempfile}" | tee "${REPORT_DIR}/summary.txt" @@ -118,5 +120,11 @@ if [[ -s "${crashes}" ]]; then fi rm -f "${crashes}" +if [[ -s "${timeouts}" ]]; then + printf "# Fork Timeout\n\n" >> "$SUMMARY_FILE" + cat "${timeouts}" | sed 's/^/ * /' >> "$SUMMARY_FILE" +fi +rm -f "${timeouts}" + ## generate counter wc -l "$REPORT_DIR/summary.txt" | awk '{print $1}'> "$REPORT_DIR/failures"