2020-10-16 12:51:39 +00:00
|
|
|
name: neofs-node tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
paths-ignore:
|
|
|
|
- '*.md'
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
paths-ignore:
|
|
|
|
- '*.md'
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
test:
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2021-06-28 14:01:31 +00:00
|
|
|
go: [ '1.16.x' ]
|
2020-10-16 12:51:39 +00:00
|
|
|
steps:
|
|
|
|
- name: Setup go
|
|
|
|
uses: actions/setup-go@v2
|
|
|
|
with:
|
|
|
|
go-version: ${{ matrix.go }}
|
|
|
|
|
|
|
|
- name: Check out code
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Cache go mod
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
|
|
|
path: ~/go/pkg/mod
|
|
|
|
key: ${{ runner.os }}-go-${{ matrix.go }}-${{ hashFiles('**/go.sum') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-go-${{ matrix.go }}-
|
|
|
|
|
|
|
|
- name: Run go test
|
|
|
|
run: go test -coverprofile=coverage.txt -covermode=atomic ./...
|
|
|
|
|
|
|
|
- name: Codecov
|
|
|
|
env:
|
|
|
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
|
|
|
run: bash <(curl -s https://codecov.io/bash)
|
|
|
|
|
|
|
|
lint:
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
|
|
- name: Check out code
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: golangci-lint
|
|
|
|
uses: golangci/golangci-lint-action@v2
|
|
|
|
with:
|
2020-11-18 16:27:05 +00:00
|
|
|
version: v1.30
|
|
|
|
args: --timeout=5m
|
2020-10-16 12:51:39 +00:00
|
|
|
only-new-issues: true
|