github.com/nsqio/nsq@v1.3.0/.github/workflows/test.yml (about)

     1  name: tests
     2  
     3  on:
     4    push:         {branches: [master]}
     5    pull_request: {branches: [master]}
     6  
     7  jobs:
     8    test:
     9      runs-on: ubuntu-20.04
    10      timeout-minutes: 30
    11      strategy:
    12        fail-fast: false
    13        matrix:
    14          go:   ["1.18.x", "1.19.x", "1.20.x"]
    15          arch: ["amd64", "386"]
    16  
    17      env:
    18        GOARCH: "${{matrix.arch}}"
    19  
    20      steps:
    21        - uses: actions/checkout@v2
    22  
    23        - uses: WillAbides/setup-go-faster@v1.7.0
    24          with:
    25            go-version: ${{matrix.go}}
    26  
    27        - name: build
    28          run: make all
    29  
    30        - name: test
    31          run: ./test.sh
    32  
    33    staticcheck:
    34      runs-on: ubuntu-20.04
    35      steps:
    36        - uses: actions/checkout@v2
    37  
    38        - uses: dominikh/staticcheck-action@v1.3.0
    39          with:
    40            version: "2023.1.3"
    41            install-go: false
    42  
    43    code-coverage:
    44      runs-on: ubuntu-20.04
    45      steps:
    46        - uses: actions/checkout@v2
    47  
    48        - name: install goveralls
    49          run: go install github.com/mattn/goveralls@latest
    50  
    51        - name: send coverage
    52          env:
    53            COVERALLS_TOKEN: ${{secrets.GITHUB_TOKEN}}
    54          run: ./coverage.sh --coveralls