Skip to content

Commit

Permalink
test: run ineffassign in fmt pass
Browse files Browse the repository at this point in the history
Signed-off-by: Gyu-Ho Lee <[email protected]>
  • Loading branch information
gyuho committed Oct 3, 2017
1 parent 46223a2 commit 72fbe05
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,17 @@ function fmt_pass {
echo "Skipping staticcheck..."
fi

if which ineffassign >/dev/null; then
echo "Checking ineffassign..."
ineffassignResult=$(ineffassign "${STATIC_ANALYSIS_PATHS[@]}" 2>&1 || true)
if [ -n "${ineffassignResult}" ]; then
echo -e "ineffassign checking failed:\n${ineffassignResult}"
exit 255
fi
else
echo "Skipping ineffassign..."
fi

echo "Checking for license header..."
licRes=""
files=$(find . -type f -iname '*.go' ! -path './cmd/*' ! -path './gopath.proto/*')
Expand Down

0 comments on commit 72fbe05

Please sign in to comment.