File: ci.yml

package info (click to toggle)
fq 0.9.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 106,624 kB
  • sloc: xml: 2,835; makefile: 250; sh: 241; exp: 57; ansic: 21
file content (54 lines) | stat: -rw-r--r-- 1,280 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: CI

on:
  push:
    branches:
      - "master"
  pull_request:

env:
  GOLANGCILINT_VERSION: "1.55.2"

jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/setup-go@v3
        with:
          go-version: "1.21.4"
      - 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
            test_target: test-race
          # build and test on 32 bit, does not support race
          - os: ubuntu-latest
            goarch: "386"
            test_target: test
          - os: macos-latest
            goarch: amd64
            test_target: test
          - os: windows-latest
            goarch: amd64
            test_target: test
    runs-on: ${{ matrix.os }}
    steps:
      # only run cli binary tests on linux
      - name: Install expect
        if: ${{ matrix.os == 'ubuntu-latest' }}
        run: sudo apt-get install expect
      - uses: actions/checkout@v3
      - uses: actions/setup-go@v3
        with:
          go-version: "1.21.4"
      - name: Test
        env:
          GOARCH: ${{ matrix.goarch }}
        run: make ${{ matrix.test_target }}