mirror of https://github.com/goccy/go-json.git
Add coverage job
This commit is contained in:
parent
1b13407cee
commit
00886d93f1
|
@ -1,7 +1,7 @@
|
||||||
name: Go
|
name: Go
|
||||||
on: [push, pull_request]
|
on: [push, pull_request]
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
test:
|
||||||
name: Test
|
name: Test
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
|
@ -13,17 +13,12 @@ jobs:
|
||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v2
|
||||||
with:
|
with:
|
||||||
go-version: ${{ matrix.go-version }}
|
go-version: ${{ matrix.go-version }}
|
||||||
id: go
|
|
||||||
|
|
||||||
- name: Check out code into the Go module directory
|
- name: Check out code into the Go module directory
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: Test
|
- name: Test
|
||||||
run: go test -v -coverprofile=coverage.out ./ -count=1
|
run: go test -v ./ -count=1
|
||||||
|
|
||||||
- name: Report coverage
|
|
||||||
run: |
|
|
||||||
bash <(curl -s https://codecov.io/bash)
|
|
||||||
|
|
||||||
# - name: Test with GC
|
# - name: Test with GC
|
||||||
# run: go test -v ./ -count=1
|
# run: go test -v ./ -count=1
|
||||||
|
@ -32,3 +27,18 @@ jobs:
|
||||||
|
|
||||||
# - name: Test with race detector
|
# - name: Test with race detector
|
||||||
# run: go test -v -race ./ -count=1
|
# run: go test -v -race ./ -count=1
|
||||||
|
coverage:
|
||||||
|
name: Coverage
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: setup Go
|
||||||
|
uses: actions/setup-go@v2
|
||||||
|
with:
|
||||||
|
go-version: 1.15
|
||||||
|
- name: checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: measure coverage
|
||||||
|
run: go test -v -coverprofile=coverage.out ./ -count=1
|
||||||
|
- name: report coverage
|
||||||
|
run: |
|
||||||
|
bash <(curl -s https://codecov.io/bash)
|
||||||
|
|
Loading…
Reference in New Issue