on: [push, pull_request]
name: Test Go
permissions:
  contents: read
jobs:
  test:
    strategy:
      matrix:
        go-version: [1.23.x, 1.24.x]
        os: [ubuntu-latest, macos-latest]
    runs-on: ${{ matrix.os }}
    steps:
    - uses: actions/setup-go@0aaccfd150d50ccaeb58ebd88d36e91967a5f35b # v5.4.0
      with:
        go-version: ${{ matrix.go-version }}
    - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
    - run: go test -race -covermode=atomic -coverprofile=coverage.out ./...
    - uses: codecov/codecov-action@0565863a31f2c772f9f0395002a31e3f06189574 # v5.4.0
