Skip to content

Commit ddb0bc0

Browse files
committed
chore: run tests in all packages
1 parent 98a8502 commit ddb0bc0

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

Makefile

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
1-
PACKAGE_DIRS := $(shell find . -mindepth 2 -type f -name 'go.mod' -exec dirname {} \; | sort)
1+
GO_MOD_DIRS := $(shell find . -mindepth 2 -type f -name 'go.mod' -exec dirname {} \; | sort)
22

33
test: testdeps
4-
go test ./...
5-
go test ./... -short -race
6-
go test ./... -run=NONE -bench=. -benchmem
7-
env GOOS=linux GOARCH=386 go test ./...
8-
go vet
4+
set -e; for dir in $(GO_MOD_DIRS); do \
5+
echo "go test in $${dir}"; \
6+
(cd "$${dir}" && \
7+
go test && \
8+
go test ./... -short -race &&
9+
go test ./... -run=NONE -bench=. -benchmem &&
10+
env GOOS=linux GOARCH=386 go test && \
11+
go vet); \
12+
done
913
cd internal/customvet && go build .
1014
go vet -vettool ./internal/customvet/customvet
1115

@@ -28,7 +32,7 @@ fmt:
2832
goimports -w -local github.com/redis/go-redis ./
2933

3034
go_mod_tidy:
31-
set -e; for dir in $(PACKAGE_DIRS); do \
35+
set -e; for dir in $(GO_MOD_DIRS); do \
3236
echo "go mod tidy in $${dir}"; \
3337
(cd "$${dir}" && \
3438
go get -u ./... && \

0 commit comments

Comments
 (0)