YETUS-354. findbugs in build driver has problems Signed-off-by: Allen Wittenauer <[email protected]>
Project: http://git-wip-us.apache.org/repos/asf/yetus/repo Commit: http://git-wip-us.apache.org/repos/asf/yetus/commit/24be6d35 Tree: http://git-wip-us.apache.org/repos/asf/yetus/tree/24be6d35 Diff: http://git-wip-us.apache.org/repos/asf/yetus/diff/24be6d35 Branch: refs/heads/YETUS-156 Commit: 24be6d3554505e18758c3d2d81017b8a7659d498 Parents: 102df11 Author: Allen Wittenauer <[email protected]> Authored: Mon Apr 11 10:45:18 2016 -0700 Committer: Allen Wittenauer <[email protected]> Committed: Sun Apr 17 10:14:34 2016 -0700 ---------------------------------------------------------------------- precommit/test-patch.d/findbugs.sh | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/yetus/blob/24be6d35/precommit/test-patch.d/findbugs.sh ---------------------------------------------------------------------- diff --git a/precommit/test-patch.d/findbugs.sh b/precommit/test-patch.d/findbugs.sh index 152d85f..24ccc95 100755 --- a/precommit/test-patch.d/findbugs.sh +++ b/precommit/test-patch.d/findbugs.sh @@ -281,9 +281,19 @@ function findbugs_preapply if [[ ${module_findbugs_warnings} -gt 0 ]] ; then msg="${module} in ${PATCH_BRANCH} has ${module_findbugs_warnings} extant Findbugs warnings." - if [[ "${FINDBUGS_WARNINGS_FAIL_PRECHECK}" == "true" ]]; then + if [[ "${FINDBUGS_WARNINGS_FAIL_PRECHECK}" = "true" ]]; then module_status ${modindex} -1 "branch-findbugs-${fn}-warnings.html" "${msg}" ((result=result+1)) + elif [[ "${BUILDMODE}" = full ]]; then + module_status ${modindex} -1 "branch-findbugs-${fn}-warnings.html" "${msg}" + ((result=result+1)) + populate_test_table FindBugs "module:${module}" + #shellcheck disable=SC2162 + while read line; do + firstpart=$(echo "${line}" | cut -f2 -d:) + secondpart=$(echo "${line}" | cut -f9- -d' ') + add_test_table "" "${firstpart}:${secondpart}" + done < <("${FINDBUGS_HOME}/bin/convertXmlToText" "${warnings_file}.xml") else module_status ${modindex} 0 "branch-findbugs-${fn}-warnings.html" "${msg}" fi @@ -466,7 +476,7 @@ function findbugs_rebuild { declare repostatus=$1 - if [[ "${repostatus}" = branch ]]; then + if [[ "${repostatus}" = branch || "${BUILDMODE}" = full ]]; then findbugs_preapply else findbugs_postinstall
