2020-04-09 12:01:40 +01:00
|
|
|
name: CI
|
2020-03-26 21:43:52 +00:00
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
jobs:
|
2020-03-30 12:15:21 +01:00
|
|
|
tests-go-1-14:
|
2020-03-30 11:59:02 +01:00
|
|
|
runs-on: ubuntu-latest
|
2020-03-26 21:43:52 +00:00
|
|
|
env:
|
2020-03-30 11:52:42 +01:00
|
|
|
GO111MODULE: on
|
2020-03-26 21:43:52 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout Source
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Run Tests
|
2020-03-30 12:20:59 +01:00
|
|
|
uses: cedrickring/golang-action@1.5.1
|
2020-03-30 12:15:21 +01:00
|
|
|
with:
|
|
|
|
args: make test
|
|
|
|
tests-go-1-13:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
GO111MODULE: on
|
|
|
|
steps:
|
|
|
|
- name: Checkout Source
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Run Tests
|
|
|
|
uses: cedrickring/golang-action/go1.13@1.5.1
|
|
|
|
with:
|
|
|
|
args: make test
|
|
|
|
tests-go-1-12:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
GO111MODULE: on
|
|
|
|
steps:
|
|
|
|
- name: Checkout Source
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Run Tests
|
|
|
|
uses: cedrickring/golang-action/go1.12@1.5.1
|
2020-03-30 12:06:29 +01:00
|
|
|
with:
|
|
|
|
args: make test
|
2020-03-26 21:43:52 +00:00
|
|
|
coverage:
|
2020-03-30 12:16:53 +01:00
|
|
|
needs: [tests-go-1-14, tests-go-1-13, tests-go-1-12]
|
2020-03-26 21:43:52 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
2020-03-30 11:52:42 +01:00
|
|
|
GO111MODULE: on
|
2020-03-26 21:43:52 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout Source
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Create Test Coverage
|
2020-03-30 12:06:29 +01:00
|
|
|
uses: cedrickring/golang-action@1.5.1
|
|
|
|
with:
|
|
|
|
args: make test-coverage
|
2020-03-26 21:43:52 +00:00
|
|
|
- name: Upload Test Coverage
|
|
|
|
uses: codecov/codecov-action@v1
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
|
|
|
file: ./coverage.txt
|
|
|
|
fail_ci_if_error: true
|