diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6e1583d74..ed695ee6f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -7,7 +7,7 @@ env: REACT_APP_API_BASE_URL: http://localhost:8080 APP_SHA: ${{ github.sha }} APP_REF: ${{ github.ref }} - # LD_LIBRARY_PATH: /tmp + LD_LIBRARY_PATH: /tmp PACT_GO_LIB_DOWNLOAD_PATH: /tmp LOG_LEVEL: info COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -19,8 +19,8 @@ jobs: go-version: [ # https://endoflife.date/go # 1.17.x, # Ended 02 Aug 2022 # 1.18.x, # Ended 01 Feb 2023 - 1.19.x, # Ended 8 Aug 2023 - 1.20.x, + # 1.19.x, # Ended 8 Aug 2023 + # 1.20.x, 1.21.x ] os: [ @@ -44,7 +44,7 @@ jobs: java-version: '17' - name: Deps - if: matrix.os == 'macos-14' + # if: matrix.os == 'macos-14' run: brew install protobuf - name: Unit Test (with examples) @@ -96,22 +96,22 @@ jobs: - name: Test examples run: docker run --rm -e PACT_DO_NOT_TRACK=true pact-go-test:amd64-alpine /bin/sh -c 'make install && make download_plugins && make pact' if: always() - test_alpine_arm64: - runs-on: [ubuntu-latest] - steps: - - name: Checkout code - uses: actions/checkout@v4 - - name: Set up QEMU - if: runner.os == 'Linux' - uses: docker/setup-qemu-action@v3 - - name: Build image - run: docker build . --progress plain --platform=linux/arm64 -t pact-go-test:arm64-alpine - - name: Test Unit - run: docker run --platform=linux/arm64 --rm -e PACT_DO_NOT_TRACK=true pact-go-test:arm64-alpine - if: always() - - name: Test examples - run: docker run --platform=linux/arm64 --rm -e PACT_DO_NOT_TRACK=true pact-go-test:arm64-alpine /bin/sh -c 'make install && make download_plugins && make pact' - if: always() + # test_alpine_arm64: + # runs-on: [ubuntu-latest] + # steps: + # - name: Checkout code + # uses: actions/checkout@v4 + # - name: Set up QEMU + # if: runner.os == 'Linux' + # uses: docker/setup-qemu-action@v3 + # - name: Build image + # run: docker build . --progress plain --platform=linux/arm64 -t pact-go-test:arm64-alpine + # - name: Test Unit + # run: docker run --platform=linux/arm64 --rm -e PACT_DO_NOT_TRACK=true pact-go-test:arm64-alpine + # if: always() + # - name: Test examples + # run: docker run --platform=linux/arm64 --rm -e PACT_DO_NOT_TRACK=true pact-go-test:arm64-alpine /bin/sh -c 'make install && make download_plugins && make pact' + # if: always() # finish: diff --git a/Makefile b/Makefile index 56c3346e4..94ab8e61b 100755 --- a/Makefile +++ b/Makefile @@ -62,8 +62,8 @@ install: bin pact: @echo "--- 🔨 Running Pact examples" - go test -v -tags=consumer github.com/pact-foundation/pact-go/v2/examples/... - go test -v -timeout=30s -tags=provider github.com/pact-foundation/pact-go/v2/examples/... + go test -v -count=1 -tags=consumer github.com/pact-foundation/pact-go/v2/examples/... + go test -v -count=1 -timeout=30s -tags=provider github.com/pact-foundation/pact-go/v2/examples/... publish: @echo "-- 📃 Publishing pacts" @@ -79,7 +79,7 @@ test: deps install @echo "mode: count" > coverage.txt @for d in $$(go list ./... | grep -v vendor | grep -v examples); \ do \ - go test -v -coverprofile=profile.out -covermode=atomic $$d; \ + go test -count=1 -v -coverprofile=profile.out -covermode=atomic $$d; \ if [ $$? != 0 ]; then \ exit 1; \ fi; \