35 lines
742 B
YAML
35 lines
742 B
YAML
|
name: ci
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
branches:
|
||
|
- '**'
|
||
|
tags-ignore:
|
||
|
- '*.*'
|
||
|
pull_request:
|
||
|
|
||
|
env:
|
||
|
GO111MODULE: on
|
||
|
|
||
|
jobs:
|
||
|
tests:
|
||
|
name: Tests
|
||
|
runs-on: ubuntu-latest
|
||
|
strategy:
|
||
|
matrix:
|
||
|
go-version: ['1.11', '1.12', '1.13', '1.14', '1.15']
|
||
|
steps:
|
||
|
- name: Set up Go ${{ matrix.go-version }}
|
||
|
uses: actions/setup-go@v2
|
||
|
with:
|
||
|
go-version: ${{ matrix.go-version }}
|
||
|
- name: Check out code into the Go module directory
|
||
|
uses: actions/checkout@v2
|
||
|
- name: Get dependencies
|
||
|
run: go mod tidy
|
||
|
- name: Tests
|
||
|
run: |
|
||
|
go test -v ./...
|
||
|
go build ./examples/...
|
||
|
- name: Coverage
|
||
|
run: bash <(curl -s https://codecov.io/bash)
|