Skip to content

Add go 1.21 to test matrix #10

Add go 1.21 to test matrix

Add go 1.21 to test matrix #10

Workflow file for this run

name: Go
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
test:
strategy:
matrix:
go-version: ['1.16', '1.18', '1.19', '1.21']
# os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ubuntu-latest
# runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@master
- uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go-version }}
- name: Build project
run: go build -v .
- name: Run tests
run: go test -race -coverprofile=coverage.txt -covermode=atomic
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: ./coverage.txt
gcov_ignore: ./countries.go
golangci:
name: golangci-lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Run golangci-lint
uses: golangci/golangci-lint-action@v2