1
1
mirror of https://github.com/wader/fq.git synced 2024-11-23 09:56:07 +03:00
fq/.github/workflows/ci.yml

56 lines
1.3 KiB
YAML
Raw Normal View History

2020-06-08 03:29:51 +03:00
name: CI
on:
push:
branches:
- "master"
2020-06-08 03:29:51 +03:00
pull_request:
env:
GOLANGCILINT_VERSION: 1.49.0
2020-06-08 03:29:51 +03:00
jobs:
lint:
2020-06-08 03:29:51 +03:00
runs-on: ubuntu-latest
steps:
2022-03-12 22:00:13 +03:00
- uses: actions/setup-go@v3
with:
go-version: 1.19.0
2022-03-12 22:00:13 +03:00
- uses: actions/checkout@v3
- uses: golangci/golangci-lint-action@v3
with:
version: v${{ env.GOLANGCILINT_VERSION }}
test:
strategy:
matrix:
include:
- os: ubuntu-latest
goarch: amd64
go_test_race_flags: -race
# build and test on 32 bit, does not support race
- os: ubuntu-latest
goarch: "386"
go_test_race_flags: ""
- os: macos-latest
goarch: amd64
go_test_race_flags: ""
- os: windows-latest
goarch: amd64
go_test_race_flags: ""
runs-on: ${{ matrix.os }}
steps:
# only run cli binary tests on linux
2021-09-18 19:11:51 +03:00
- name: Install expect
if: ${{ matrix.os == 'ubuntu-latest' }}
2021-09-18 19:11:51 +03:00
run: sudo apt-get install expect
2022-03-12 22:00:13 +03:00
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
2020-06-08 03:29:51 +03:00
with:
go-version: 1.19.0
2020-06-08 03:29:51 +03:00
- name: Test
env:
GOARCH: ${{ matrix.goarch }}
GO_TEST_RACE_FLAGS: ${{ matrix.go_test_race_flags }}
2020-06-08 03:29:51 +03:00
run: make test