From 7e130de3aa8e3598482f33497db5fab634051025 Mon Sep 17 00:00:00 2001 From: Doug <6060466+pixlwave@users.noreply.github.com> Date: Thu, 7 Mar 2024 18:55:02 +0000 Subject: [PATCH] Zip results from Unit Test failures (#2542) * Zip uploaded unit test results on failure. Add a failure to test. Revert "Add a failure to test." --- .github/workflows/unit_tests.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/unit_tests.yml b/.github/workflows/unit_tests.yml index 0e3cc95f3..7b7a6bfbd 100644 --- a/.github/workflows/unit_tests.yml +++ b/.github/workflows/unit_tests.yml @@ -49,13 +49,18 @@ jobs: - name: Run tests run: bundle exec fastlane unit_tests + - name: Zip results # for faster upload + if: failure() + working-directory: fastlane/test_output + run: zip -r UnitTests.zip UnitTests.xcresult PreviewTests.xcresult + - name: Archive artifacts uses: actions/upload-artifact@v3 - # We only care about artifcats if the tests fail + # We only care about artefacts if the tests fail if: failure() with: - name: test-output - path: fastlane/test_output + name: Results + path: fastlane/test_output/UnitTests.zip retention-days: 1 if-no-files-found: ignore