Skip to content

Fix/several fixes

Fix/several fixes #371

Workflow file for this run

name: lint & test workflow
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
- cron: '0 0 * * *'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
lint:
if: ${{ github.event_name == 'pull_request' }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version-file: './go.mod'
cache-dependency-path: './go.sum'
- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: latest
working-directory: '.'
test:
runs-on: ubuntu-latest
services:
postgres:
image: postgres
env:
POSTGRES_HOST_AUTH_METHOD: trust
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
strategy:
matrix:
go: [ 'oldstable', 'stable' ]
name: test with Go version ${{ matrix.go }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- run: make test/cov/report
working-directory: '.'
- name: Upload coverage reports to Codecov
if: always()
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }} # required