Skip to content

Commit c2e83fa

Browse files

File tree

3 files changed

+20
-0
lines changed

3 files changed

+20
-0
lines changed

.github/workflows/testing.yml

+9
Original file line numberDiff line numberDiff line change
@@ -44,3 +44,12 @@ jobs:
4444

4545
- name: Run tests
4646
run: make test
47+
48+
- name: Run tests, collect code coverage data and send to Coveralls
49+
if: ${{ matrix.tarantool }} == '2.9'
50+
env:
51+
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
52+
run: |
53+
go get golang.org/x/tools/cmd/cover
54+
go get github.com/mattn/goveralls
55+
make coveralls

Makefile

+10
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
SHELL := /bin/bash
2+
COVERAGE_FILE := coverage.out
23

34
.PHONY: clean
45
clean:
@@ -12,3 +13,12 @@ deps: clean
1213
test:
1314
go clean -testcache
1415
go test ./... -v -p 1
16+
17+
.PHONY: coverage
18+
coverage:
19+
go clean -testcache
20+
go test ./... -v -p 1 -covermode=count -coverprofile=$(COVERAGE_FILE)
21+
22+
.PHONY: coveralls
23+
coveralls: coverage
24+
goveralls -coverprofile=$(COVERAGE_FILE) -service=github

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
<!--a href="https://travis-ci.org/tarantool/go-tarantool">
55
<img src="https://travis-ci.org/tarantool/go-tarantool.png?branch=master" align="right">
66
</a-->
7+
[![Coverage Status](https://coveralls.io/repos/github/tarantool/go-tarantool/badge.svg?branch=master)](https://coveralls.io/github/tarantool/go-tarantool?branch=master)
78

89
# Client in Go for Tarantool 1.6+
910

0 commit comments

Comments
 (0)