From efb2ffbf3358490eba59add8258409dcd0e0d459 Mon Sep 17 00:00:00 2001 From: teor Date: Mon, 28 Jun 2021 16:35:52 +1000 Subject: [PATCH] Stop ignoring failed cached state tests Previously, Zebra's cached state workflows would run all of Zebra's tests, but they would ignore the results for most tests. They would only fail if the mainnet cached state test failed. After this fix, the tests fail if any test or build step fails. --- .github/workflows/regenerate-stateful-test-disks.yml | 10 +++++----- .github/workflows/test.yml | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/regenerate-stateful-test-disks.yml b/.github/workflows/regenerate-stateful-test-disks.yml index 2aa5805e..a016defd 100644 --- a/.github/workflows/regenerate-stateful-test-disks.yml +++ b/.github/workflows/regenerate-stateful-test-disks.yml @@ -16,7 +16,7 @@ jobs: - uses: actions/checkout@v2.3.4 with: persist-credentials: false - + - name: Set project and image names run: | BRANCH_NAME=$(expr $GITHUB_REF : '.*/\(.*\)') && \ @@ -62,10 +62,10 @@ jobs: - name: Run all tests run: | gcloud compute ssh "zebrad-tests-$BRANCH_NAME-$SHORT_SHA" --zone "$ZONE" --command \ - "git clone -b $BRANCH_NAME https://github.com/ZcashFoundation/zebra.git; - cd zebra/; - docker build --build-arg SHORT_SHA=$SHORT_SHA -f docker/Dockerfile.test -t zebrad-test .; - docker run -i --mount type=bind,source=/mnt/disks/gce-containers-mounts/gce-persistent-disks/zebrad-cache-$SHORT_SHA-mainnet-1046400,target=/zebrad-cache zebrad-test:latest cargo test --verbose --features test_sync_past_mandatory_checkpoint_mainnet --manifest-path zebrad/Cargo.toml sync_past_mandatory_checkpoint_mainnet; + "git clone -b $BRANCH_NAME https://github.com/ZcashFoundation/zebra.git && + cd zebra/ && + docker build --build-arg SHORT_SHA=$SHORT_SHA -f docker/Dockerfile.test -t zebrad-test . && + docker run -i --mount type=bind,source=/mnt/disks/gce-containers-mounts/gce-persistent-disks/zebrad-cache-$SHORT_SHA-mainnet-1046400,target=/zebrad-cache zebrad-test:latest cargo test --verbose --features test_sync_past_mandatory_checkpoint_mainnet --manifest-path zebrad/Cargo.toml sync_past_mandatory_checkpoint_mainnet && docker run -i --mount type=bind,source=/mnt/disks/gce-containers-mounts/gce-persistent-disks/zebrad-cache-$SHORT_SHA-testnet-1028500,target=/zebrad-cache zebrad-test:latest cargo test --verbose --features test_sync_past_mandatory_checkpoint_testnet --manifest-path zebrad/Cargo.toml sync_past_mandatory_checkpoint_testnet; " # Clean up diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fa229ba8..3624c0c6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -19,7 +19,7 @@ jobs: - uses: actions/checkout@v2.3.4 with: persist-credentials: false - + - name: Set project and image names run: | BRANCH_NAME=$(expr $GITHUB_REF : '.*/\(.*\)') && \ @@ -65,10 +65,10 @@ jobs: - name: Run all tests run: | gcloud compute ssh "zebrad-tests-$BRANCH_NAME-$SHORT_SHA" --zone "$ZONE" --command \ - "git clone -b $BRANCH_NAME https://github.com/ZcashFoundation/zebra.git; - cd zebra/; - docker build --build-arg SHORT_SHA=$SHORT_SHA -f docker/Dockerfile.test -t zebrad-test .; - docker run -i zebrad-test cargo test --workspace --no-fail-fast -- -Zunstable-options --include-ignored; + "git clone -b $BRANCH_NAME https://github.com/ZcashFoundation/zebra.git && + cd zebra/ && + docker build --build-arg SHORT_SHA=$SHORT_SHA -f docker/Dockerfile.test -t zebrad-test . && + docker run -i zebrad-test cargo test --workspace --no-fail-fast -- -Zunstable-options --include-ignored && docker run -i --mount type=bind,source=/mnt/disks/gce-containers-mounts/gce-persistent-disks/zebrad-cache-$SHORT_SHA-mainnet-1046400,target=/zebrad-cache zebrad-test:latest cargo test --verbose --features test_sync_past_mandatory_checkpoint_mainnet --manifest-path zebrad/Cargo.toml sync_past_mandatory_checkpoint_mainnet; " # Clean up