From 588165be10771a7d9e6e69673a4e0d66eeb4c97c Mon Sep 17 00:00:00 2001 From: Daniel Wedul Date: Fri, 5 Apr 2024 14:03:56 -0600 Subject: [PATCH] Always run the build/release actions and split test building into parts. (#1911) * Update the build/release github action: Re-enable the provenanced version steps. Always run the actions, but skip the actual build steps in the cases where we were previously skipping these actions altogether. * Split the build tests stuff into 4 parts like the normal tests. * Add a change to a .go file. * Add a checkout to the build init so the diff has something to look at. * Put the release github action back like it was, but still re-enable the provenanced version steps and also remove the step that builds the tests. * Remove temporary .go change. --- .github/workflows/release.yml | 7 ------- .github/workflows/test.yml | 13 +++++++++++-- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 01654ed50b..6a60d66c68 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -74,8 +74,6 @@ jobs: export VERSION=${{ needs.build_init.outputs.version }} make build-release-zip - name: Provenanced version - # TODO[1760]: github: Re-enable the build_osx provenanced version step. - if: false run: build/provenanced version --long - uses: actions/upload-artifact@v4 with: @@ -105,12 +103,7 @@ jobs: export VERSION=${{ needs.build_init.outputs.version }} make build-release-zip - name: Provenanced version - # TODO[1760]: github: Re-enable the build_linux provenanced version step. - if: false run: build/provenanced version --long - - name: Compile Tests - # TODO[1760]: github: Delete this build_linux Compile Tests step. - run: go test -mod=readonly -timeout 30m -tags='norace ledger test_ledger_mock' -run='ZYX_NOT_A_REAL_TEST_XZY' ./... - uses: actions/upload-artifact@v4 with: name: linux-zip diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b87d5bd3d2..de7911bf50 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -112,16 +112,25 @@ jobs: build-tests: # TODO[1760]: Delete this build-tests action once the tests reliably pass again. needs: setup-tests + strategy: + fail-fast: false + matrix: + part: ["00", "01", "02", "03"] runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 if: needs.setup-tests.outputs.should-run with: go-version: ${{ needs.setup-tests.outputs.go-version }} + - uses: actions/download-artifact@v4 + if: needs.setup-tests.outputs.should-run + with: + name: "${{ needs.setup-tests.outputs.file-prefix }}-pkgs.txt.part.${{ matrix.part }}" - name: build tests + if: needs.setup-tests.outputs.should-run run: | - make build-tests + cat pkgs.txt.part.${{ matrix.part }} | xargs go test -mod=readonly -timeout 30m -tags='norace ledger test_ledger_mock' -run='ZYX_NOPE_NOPE_XYZ' # This action performs a code coverage assessment but filters out generated code from proto based types # and grpc services