mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
test: run ineffassign in fmt pass
Signed-off-by: Gyu-Ho Lee <gyuhox@gmail.com>
This commit is contained in:
parent
46223a2202
commit
72fbe0576d
11
test
11
test
@ -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/*')
|
||||
|
Loading…
x
Reference in New Issue
Block a user