Skip to content

Commit

Permalink
Upgrade codecov action
Browse files Browse the repository at this point in the history
Upgrade codecov action
  • Loading branch information
ilyakaznacheev authored Oct 5, 2022
2 parents 35edfee + 64fdf0d commit abaa96d
Show file tree
Hide file tree
Showing 4 changed files with 71 additions and 119 deletions.
42 changes: 0 additions & 42 deletions .github/workflows/build.yml

This file was deleted.

35 changes: 35 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
on:
push:
branches:
- 'master'
- 'develop'
pull_request:

jobs:
codecov:
name: codecov
runs-on: ubuntu-latest
steps:

- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: 1.19
cache: true
- name: Install dependencies
run: go get .

- name: Generate coverage report
run: |
go test `go list ./... | grep -v examples` -coverprofile=coverage.txt -covermode=atomic
- name: Upload coverage report
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.txt
flags: unittests
name: codecov-umbrella
77 changes: 0 additions & 77 deletions .github/workflows/pull_request.yml

This file was deleted.

36 changes: 36 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: test

on:
push:
branches:
- 'master'
- 'develop'
tags:
- 'v*.*.*'
pull_request:

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
go-version:
- '1.19'
- '1.18'
- '1.17'
os:
- ubuntu-latest
- macos-latest
- windows-latest

steps:
- uses: actions/checkout@v3
- name: Setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
cache: true
- name: Install dependencies
run: go get .
- name: Test with the Go CLI
run: go test ./...

0 comments on commit abaa96d

Please sign in to comment.