From f5e81e45cc009e5ab3f743653c32c1ba8a09ac81 Mon Sep 17 00:00:00 2001 From: Vladimir Varankin Date: Fri, 5 Oct 2018 14:42:25 +0200 Subject: [PATCH] fix gofmt tests output Print the whole command in "Execute ..." and "... returned 1" logs. Fix "binary operator expected" by passing quoted output from `gofmt` to `test`. --- scripts/circle-test-backend.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/circle-test-backend.sh b/scripts/circle-test-backend.sh index 959a5812d81..d25506b9bc7 100755 --- a/scripts/circle-test-backend.sh +++ b/scripts/circle-test-backend.sh @@ -11,7 +11,7 @@ function exit_if_fail { } echo "running go fmt" -exit_if_fail test -z "$(gofmt -s -l ./pkg | tee /dev/stderr)" +exit_if_fail test -z \"'$(gofmt -s -l ./pkg | tee /dev/stderr)'\" echo "building backend with install to cache pkgs" exit_if_fail time go install ./pkg/cmd/grafana-server