File tree Expand file tree Collapse file tree 4 files changed +28
-35
lines changed Expand file tree Collapse file tree 4 files changed +28
-35
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ default : test
2
+
3
+ .PHONY : test
4
+ test :
5
+ ./scripts/test.sh
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+
3
+ echo " Running tests..."
4
+ go test -v -cover -cpu 1,2,4 ./...
5
+ go test -v -cover -cpu 1,2,4 -race ./...
6
+
7
+ echo " Checking gofmt..."
8
+ # We utilize 'go fmt' to find all files suitable for formatting,
9
+ # but reuse full power gofmt to perform just RO check.
10
+ fmt_res=$( go fmt -n ./... | sed ' s| -w | -d |g' | sh)
11
+ if [ -n " ${fmt_res} " ]; then
12
+ echo -e " gofmt checking failed:\n${fmt_res} "
13
+ exit 1
14
+ fi
15
+
16
+ echo " Checking govet..."
17
+ vet_res=$( go vet ./...)
18
+ if [ -n " ${vet_res} " ]; then
19
+ echo -e " govet checking failed:\n${vet_res} "
20
+ exit 1
21
+ fi
22
+
23
+ echo " Success"
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments