1
0
mirror of https://github.com/ggicci/httpin.git synced 2024-12-02 09:01:33 +02:00

Create go.yml

This commit is contained in:
Ggicci 2021-04-22 18:36:20 +08:00 committed by GitHub
parent 8818d73d94
commit a16cc6228d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

34
.github/workflows/go.yml vendored Normal file
View File

@ -0,0 +1,34 @@
name: Go
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.16
- name: Build
run: go build -v ./...
- name: Test and generate coverage report
run: go test -race -failfast -parallel 4 -cpu 4 -coverprofile main.cover.out -v ./...
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v1
with:
name: codecov-umbrella
files: ./main.cover.out
flags: unittests
fail_ci_if_error: true
verbose: true