Merge pull request #74 from riandyrn/chore/update-otel-1.32 #57
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: compatibility-test | |
on: | |
push: | |
paths-ignore: | |
- "**.md" | |
- LICENCE | |
- CODEOWNERS | |
branches: | |
- master | |
pull_request_review: | |
types: [submitted] | |
jobs: | |
compatibility-test: | |
# we trigger the job only when the PR is approved or the job is triggered by other events | |
# defined in the on section | |
if: github.event.review.state == 'APPROVED' || github.event_name != 'pull_request_review' | |
strategy: | |
matrix: | |
go-version: ["1.22", "1.23"] | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
# GitHub Actions does not support arm* architectures on default | |
# runners. It is possible to acomplish this with a self-hosted runner | |
# if we want to add this in the future: | |
# https://docs.github.com/en/actions/hosting-your-own-runners/using-self-hosted-runners-in-a-workflow | |
arch: ["386", amd64] | |
exclude: | |
# Not a supported Go OS/architecture. | |
- os: macos-latest | |
arch: "386" | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup Environment | |
run: | | |
echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV | |
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH | |
shell: bash | |
- name: Module cache | |
uses: actions/cache@v4 | |
env: | |
cache-name: go-mod-cache | |
with: | |
path: ~/go/pkg/mod | |
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/go.sum') }} | |
- name: Run Test | |
env: | |
GOARCH: ${{ matrix.arch }} | |
run: make go-test |