name: CI
on:
  push:
    branches:
      - main
  pull_request:
jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Set up Go
        uses: actions/setup-go@v2
        with:
          go-version: 1.25
      - name: Run Go Generate
        run: go generate ./...
      - name: Run Tests
        run: go test -v -coverprofile=coverage.out ./...
      - name: Upload to Codecov
        uses: codecov/codecov-action@v2
        with:
          files: ./coverage.out
          fail_ci_if_error: false
