File tree Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ includes:
88
99vars :
1010 BIN : " {{.ROOT_DIR}}/bin"
11+ GOTESTSUM_FORMAT : ' {{if .CI}}github-actions{{else}}pkgname{{end}}'
1112
1213env :
1314 CGO_ENABLED : ' 0'
@@ -131,29 +132,37 @@ tasks:
131132 test :
132133 desc : Runs test suite
133134 aliases : [t]
135+ deps : [gotestsum:install]
134136 sources :
135137 - " **/*.go"
136138 - " testdata/**/*"
137139 cmds :
138- - go test ./...
140+ - gotestsum -f '{{.GOTESTSUM_FORMAT}}' ./...
139141
140142 test:watch :
141143 desc : Runs test suite with watch tests included
142- deps : [sleepit:build]
144+ deps : [sleepit:build, gotestsum:install ]
143145 cmds :
144- - go test ./... -tags 'watch'
146+ - gotestsum -f '{{.GOTESTSUM_FORMAT}}' ./... -tags 'watch'
145147
146148 test:all :
147149 desc : Runs test suite with signals and watch tests included
148- deps : [sleepit:build]
150+ deps : [sleepit:build, gotestsum:install ]
149151 cmds :
150- - go test -tags 'signals watch' ./...
152+ - gotestsum -f '{{.GOTESTSUM_FORMAT}}' -tags 'signals watch' ./...
151153
152154 goreleaser:test :
153155 desc : Tests release process without publishing
154156 cmds :
155157 - goreleaser --snapshot --clean
156158
159+ gotestsum:install :
160+ desc : Installs gotestsum
161+ status :
162+ - command -v gotestsum
163+ cmds :
164+ - go install gotest.tools/gotestsum@latest
165+
157166 goreleaser:install :
158167 desc : Installs goreleaser
159168 cmds :
You can’t perform that action at this time.
0 commit comments