Skip to content

Commit

Permalink
Create go.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
xuri authored Jun 9, 2021
1 parent bafe087 commit 3816253
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
on: [push, pull_request]
name: build
jobs:

test:
strategy:
matrix:
go-version: [1.15.x, 1.16.x]
os: [ubuntu-latest, macos-latest, windows-latest]
targetplatform: [x86, x64]

runs-on: ${{ matrix.os }}

steps:

- name: Install Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}

- name: Checkout code
uses: actions/checkout@v2

- name: Get dependencies
run: |
env GO111MODULE=on go vet ./...
- name: Build
run: go build -v .

- name: Test
run: env GO111MODULE=on go test -v -race ./... -coverprofile=coverage.txt -covermode=atomic

- name: Codecov
uses: codecov/codecov-action@v1
with:
file: coverage.txt
flags: unittests
name: codecov-umbrella

0 comments on commit 3816253

Please sign in to comment.