test #50
This file contains hidden or 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
| on: [pull_request] | |
| name: Test | |
| jobs: | |
| linux: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: 1.25.* | |
| - uses: actions/checkout@v3 | |
| - name: Cache golangci-lint | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/go/bin/golangci-lint | |
| key: ${{ runner.os }}-golangci-lint-v2.4.0 | |
| - name: Install Requirements | |
| run: | | |
| if [ ! -f ~/go/bin/golangci-lint ]; then | |
| curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/main/install.sh | sh -s -- -b $(go env GOPATH)/bin v2.4.0 | |
| fi | |
| go mod vendor | |
| - name: Checking Format and Testing | |
| run: make check | |
| - name: Build | |
| run: make build | |
| - name: Build E2E Docker Images | |
| run: make test-e2e-build | |
| - name: Start E2E Environment | |
| run: make test-e2e-run | |
| - name: Run E2E Tests | |
| run: make test-e2e-test | |
| - name: Show E2E Logs on Failure | |
| if: failure() | |
| run: cd docker && docker compose -f docker-compose.e2e.yml logs | |
| - name: Stop E2E Environment | |
| if: always() | |
| run: make test-e2e-clean | |
| darwin: | |
| needs: linux | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: 1.25.* | |
| - uses: actions/checkout@v3 | |
| - name: Cache golangci-lint | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/go/bin/golangci-lint | |
| key: ${{ runner.os }}-golangci-lint-v2.4.0 | |
| - name: Install Requirements | |
| run: | | |
| if [ ! -f ~/go/bin/golangci-lint ]; then | |
| curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/main/install.sh | sh -s -- -b $(go env GOPATH)/bin v2.4.0 | |
| fi | |
| go mod vendor | |
| - name: Checking Format and Testing | |
| run: make check | |
| - name: Build | |
| run: make build | |
| windows: | |
| needs: linux | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: 1.25.* | |
| - uses: actions/checkout@v3 | |
| - name: Cache golangci-lint | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/go/bin/golangci-lint.exe | |
| key: ${{ runner.os }}-golangci-lint-v2.4.0 | |
| - name: Install Requirements | |
| run: | | |
| choco install make | |
| if (-not (Test-Path ~/go/bin/golangci-lint.exe)) { | |
| go install github.com/golangci/golangci-lint/cmd/golangci-lint@v2.4.0 | |
| } | |
| go mod vendor | |
| - name: Testing | |
| run: | | |
| set GO111MODULE=on | |
| make test-windows | |
| - name: Build | |
| run: make build-windows |