Skip to content

Commit 92b218c

Browse files
authored
fix(devops):upload coverage to Codecov (#614)
1 parent 760a634 commit 92b218c

File tree

2 files changed

+13
-15
lines changed

2 files changed

+13
-15
lines changed

.github/workflows/tests.yml

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,6 @@ jobs:
2222
with:
2323
go-version: '1.17' # The Go version to download (if necessary) and use.
2424

25-
# - uses: actions/cache@v2
26-
# with:
27-
# path: ~/go/pkg/mod
28-
# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
29-
# restore-keys: |
30-
# ${{ runner.os }}-go-
31-
3225
- name: Clone blobber
3326
uses: actions/checkout@v2
3427

@@ -53,21 +46,21 @@ jobs:
5346
with:
5447
go-version: '1.17' # The Go version to download (if necessary) and use.
5548

56-
# - uses: actions/cache@v2
57-
# with:
58-
# path: ~/go/pkg/mod
59-
# key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
60-
# restore-keys: |
61-
# ${{ runner.os }}-go-
62-
6349
- name: Clone blobber
6450
uses: actions/checkout@v2
6551

6652
- name: Run tests
6753
run: |
6854
cd $GITHUB_WORKSPACE/code/go/0chain.net/
6955
CGO_ENABLED=1 go test -tags bn256 -race -coverprofile=coverage.txt -covermode=atomic ./...
70-
56+
- name: Upload coverage to Codecov
57+
uses: codecov/codecov-action@v2
58+
with:
59+
# fail_ci_if_error: true
60+
files: ./code/go/0chain.net/coverage.txt
61+
flags: Unit-Tests
62+
verbose: true
63+
7164
integration-tests:
7265
name: Integration Tests
7366
runs-on: [ubuntu-20.04]

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11

2+
[![Build](https://github.com/0chain/blobber/actions/workflows/build-&-publish-docker-image.yml/badge.svg)](https://github.com/0chain/blobber/actions/workflows/build-&-publish-docker-image.yml)
3+
[![Test](https://github.com/0chain/blobber/actions/workflows/tests.yml/badge.svg)](https://github.com/0chain/blobber/actions/workflows/tests.yml)
4+
[![GoDoc](https://godoc.org/github.com/0chain/blobber?status.png)](https://godoc.org/github.com/0chain/blobber)
5+
[![codecov](https://codecov.io/gh/0chain/blobber/branch/main/graph/badge.svg)](https://codecov.io/gh/0chain/blobber)
6+
27
# Blobber Setup
38
This readme provide instructions on how to run blobber locally
49

0 commit comments

Comments
 (0)