diff options
| author | Horus_Arch | 2015-02-23 12:13:32 +0100 |
|---|---|---|
| committer | Horus_Arch | 2015-02-23 12:13:32 +0100 |
| commit | 70d080b69a1bce3125d8d0b83e23775880241763 (patch) | |
| tree | 6fac80f9291e361045098b2ce9eb0839652e6b42 /app/Makefile | |
| parent | 00b28812fb5ab68156ead5b45b66740a4d5ca688 (diff) | |
| download | statuspage-70d080b69a1bce3125d8d0b83e23775880241763.tar.gz | |
Refactor and more unit tests.
Diffstat (limited to 'app/Makefile')
| -rw-r--r-- | app/Makefile | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/app/Makefile b/app/Makefile index c847c75..8624cd8 100644 --- a/app/Makefile +++ b/app/Makefile @@ -22,6 +22,18 @@ ifndef STATUS_HTTP_PORT export STATUS_HTTP_PORT:=8080 endif +ifdef TEST_RACE + RACE:=-race +else + RACE:= +endif + +ifdef TEST_VERBOSE + VERBOSE:=-v +else + VERBOSE:= +endif + IMPORT_FILE:=./import.go APP:=statuspage @@ -76,10 +88,17 @@ pack: (echo "Run \"make build\" first." && exit 1) test: - go test -v -race -tags general + go test $(RACE) $(VERBOSE) -tags general test_all: import - go test -v -race -tags all + go test $(RACE) $(VERBOSE) -v -tags all test_dependencies: import - go test -v -race -tags dep + go test $(RACE) $(VERBOSE) -tags dep + +benchmark: + go test $(VERBOSE) -bench=".*" -tags general + +benchmark_dependencies: import + export DB_STATUS_LOG=false + go test $(VERBOSE) -bench=".*" -tags dep |
