-
Notifications
You must be signed in to change notification settings - Fork 0
/
tests.mk
64 lines (52 loc) · 1.27 KB
/
tests.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/usr/bin/make -f
########################################
### Testing
BINDIR ?= $(GOPATH)/bin
## required to be run first by most tests
build_docker_test_image:
docker build -t tester -f ./test/docker/Dockerfile .
.PHONY: build_docker_test_image
### coverage, app, persistence, and libs tests
test_cover:
# run the go unit tests with coverage
bash test/test_cover.sh
.PHONY: test_cover
test_apps:
# run the app tests using bash
# requires `abci-cli` and `cometbft` binaries installed
bash test/app/test.sh
.PHONY: test_apps
test_integrations:
make build_docker_test_image
make tools
make install
make install_abci
make test_cover
make test_apps
make test_abci_apps
make test_abci_cli
make test_libs
.PHONY: test_integrations
test_release:
@go test -tags release $(PACKAGES)
.PHONY: test_release
test100:
@for i in {1..100}; do make test; done
.PHONY: test100
vagrant_test:
vagrant up
vagrant ssh -c 'make test_integrations'
.PHONY: vagrant_test
### go tests
test:
@echo "--> Running go test"
@go test -p 1 $(PACKAGES) -tags deadlock
.PHONY: test
test_race:
@echo "--> Running go test --race"
@go test -p 1 -v -race $(PACKAGES)
.PHONY: test_race
test_deadlock:
@echo "--> Running go test --deadlock"
@go test -p 1 -v $(PACKAGES) -tags deadlock
.PHONY: test_race