This repository was archived by the owner on Jul 15, 2018. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +122
-21
lines changed
Expand file tree Collapse file tree 3 files changed +122
-21
lines changed Original file line number Diff line number Diff line change 1+ version : 2
2+
3+ defaults : &defaults
4+ working_directory : /go/src/github.com/tendermint/abci
5+ docker :
6+ - image : circleci/golang:1.10.0
7+ environment :
8+ GOBIN : /tmp/workspace/bin
9+
10+ jobs :
11+ setup_dependencies :
12+ << : *defaults
13+ steps :
14+ - run : mkdir -p /tmp/workspace/bin
15+ - run : mkdir -p /tmp/workspace/profiles
16+ - checkout
17+ - restore_cache :
18+ keys :
19+ - v1-pkg-cache
20+ - run :
21+ name : tools
22+ command : |
23+ export PATH="$GOBIN:$PATH"
24+ make get_tools
25+ - run :
26+ name : dependencies
27+ command : |
28+ export PATH="$GOBIN:$PATH"
29+ make get_vendor_deps
30+ - run :
31+ name : binaries
32+ command : |
33+ export PATH="$GOBIN:$PATH"
34+ make install
35+ - persist_to_workspace :
36+ root : /tmp/workspace
37+ paths :
38+ - bin
39+ - profiles
40+ - save_cache :
41+ key : v1-pkg-cache
42+ paths :
43+ - /go/pkg
44+ - save_cache :
45+ key : v1-tree-{{ .Environment.CIRCLE_SHA1 }}
46+ paths :
47+ - /go/src/github.com/tendermint/abci
48+
49+ test_integration :
50+ << : *defaults
51+ steps :
52+ - attach_workspace :
53+ at : /tmp/workspace
54+ - restore_cache :
55+ key : v1-pkg-cache
56+ - restore_cache :
57+ key : v1-tree-{{ .Environment.CIRCLE_SHA1 }}
58+ - run :
59+ name : Run integration tests
60+ command : |
61+ find . -path ./vendor -prune -o -name "*.sock" -exec rm {} \;
62+ bash tests/test.sh
63+
64+ test_cover :
65+ << : *defaults
66+ parallelism : 4
67+ steps :
68+ - attach_workspace :
69+ at : /tmp/workspace
70+ - restore_cache :
71+ key : v1-pkg-cache
72+ - restore_cache :
73+ key : v1-tree-{{ .Environment.CIRCLE_SHA1 }}
74+ - run :
75+ name : Run test cover
76+ command : |
77+ for pkg in $(go list github.com/tendermint/abci/... | grep -v /vendor/ | circleci tests split --split-by=timings); do
78+ id=$(basename "$pkg")
79+ go test -timeout 5m -race -coverprofile=/tmp/workspace/profiles/$id.out -covermode=atomic "$pkg"
80+ done
81+ - persist_to_workspace :
82+ root : /tmp/workspace
83+ paths :
84+ - " profiles/*"
85+
86+ upload_coverage :
87+ << : *defaults
88+ steps :
89+ - attach_workspace :
90+ at : /tmp/workspace
91+ - restore_cache :
92+ key : v1-tree-{{ .Environment.CIRCLE_SHA1 }}
93+ - run :
94+ name : gather
95+ command : |
96+ set -ex
97+
98+ echo "mode: atomic" > coverage.txt
99+ for prof in $(ls /tmp/workspace/profiles/); do
100+ tail -n +2 /tmp/workspace/profiles/"$prof" >> coverage.txt
101+ done
102+ - run :
103+ name : upload
104+ command : bash <(curl -s https://codecov.io/bash) -f coverage.txt
105+
106+ workflows :
107+ version : 2
108+ test-suite :
109+ jobs :
110+ - setup_dependencies
111+ - test_cover :
112+ requires :
113+ - setup_dependencies
114+ - test_integration :
115+ requires :
116+ - setup_dependencies
117+ - upload_coverage :
118+ requires :
119+ - test_integrations
120+
121+
Original file line number Diff line number Diff line change 33types /types.pb.go
44* .sw [op ]
55abci-cli
6+ coverage.txt
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments