Removing interface and adding any #147
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
on: [push, pull_request] | |
name: Test | |
jobs: | |
lint: | |
name: lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@v2 | |
with: | |
version: latest | |
test: | |
strategy: | |
matrix: | |
go-version: [stable,oldstable] | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Test | |
run: go test ./... | |
runexamples: | |
strategy: | |
matrix: | |
go-version: [stable,oldstable] | |
os: [ubuntu-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Test Examples | |
run: for EX in $(ls _examples); do go run ./_examples/$EX; done | |
coverage: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 2 | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: 'stable' | |
- name: Run coverage | |
run: go test -race -coverprofile=coverage.txt -covermode=atomic | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 |