2023-02-05 23:17:13 +03:00
|
|
|
name: CI
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2023-08-04 12:13:03 +03:00
|
|
|
branches: [master]
|
2023-02-05 23:17:13 +03:00
|
|
|
pull_request:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2023-02-05 23:21:24 +03:00
|
|
|
name: Build
|
2023-02-05 23:17:13 +03:00
|
|
|
runs-on: ${{ matrix.os }}
|
2023-08-04 12:13:03 +03:00
|
|
|
|
2023-02-05 23:17:13 +03:00
|
|
|
strategy:
|
|
|
|
# Fail fast is disabled because there are Go version specific features and tests
|
|
|
|
# that should be able to fail independently.
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
os: [ubuntu-latest, windows-latest]
|
2023-02-05 23:17:45 +03:00
|
|
|
go-version: ['1.16', '1.17', '1.18', '1.19', '1.20']
|
2023-02-05 23:17:13 +03:00
|
|
|
|
|
|
|
steps:
|
2023-08-04 12:13:03 +03:00
|
|
|
- name: Checkout repository
|
|
|
|
uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3
|
|
|
|
|
2023-02-05 23:17:13 +03:00
|
|
|
- name: Set up Go
|
2023-08-04 12:13:03 +03:00
|
|
|
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1
|
2023-02-05 23:17:13 +03:00
|
|
|
with:
|
|
|
|
go-version: ${{ matrix.go }}
|
|
|
|
|
|
|
|
- name: Build
|
|
|
|
run: go build -v ./...
|
|
|
|
|
|
|
|
- name: Test
|
|
|
|
run: go test -race -v ./...
|