From dd2689905fcb77a65f190705ba5f2b793535e28c Mon Sep 17 00:00:00 2001 From: "Bobby R. Bruce" Date: Sun, 21 Apr 2024 09:15:20 -0700 Subject: [PATCH] misc,tests: Remove zip step from Workflows (#1048) This is not needed with upload-artifact v4 directories are archived and compressed by default. This zip step was also causing Daily/Weekly test failures due to not running `apt update` before the `apt install` for the zip utility. Ergo this patch fixes these errors. --- .github/workflows/ci-tests.yaml | 2 +- .github/workflows/daily-tests.yaml | 18 ++++-------------- .github/workflows/weekly-tests.yaml | 9 ++------- 3 files changed, 7 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci-tests.yaml b/.github/workflows/ci-tests.yaml index a1aebe82ac..663e7219ac 100644 --- a/.github/workflows/ci-tests.yaml +++ b/.github/workflows/ci-tests.yaml @@ -175,7 +175,7 @@ jobs: run: echo "sanatized-test-dir=$(echo '${{ matrix.test-dir }}' | sed 's/\//-/g')" >> $GITHUB_OUTPUT # Upload the tests/testing-results directory as an artifact. - - name: Upload test results + - name: upload results if: success() || failure() uses: actions/upload-artifact@v4 with: diff --git a/.github/workflows/daily-tests.yaml b/.github/workflows/daily-tests.yaml index 73788d3c9c..efa5943186 100644 --- a/.github/workflows/daily-tests.yaml +++ b/.github/workflows/daily-tests.yaml @@ -157,19 +157,14 @@ jobs: - name: long ${{ matrix.test-type }} tests working-directory: ${{ github.workspace }}/tests run: ./main.py run gem5/${{ matrix.test-type }} --length=long --skip-build -vv -t $(nproc) - - name: create zip of results - if: success() || failure() - run: | - apt-get -y install zip - zip -r output.zip tests/testing-results - - name: upload zip + - name: upload results if: success() || failure() uses: actions/upload-artifact@v4 env: MY_STEP_VAR: ${{ matrix.test-type }}_COMMIT.${{github.sha}}_RUN.${{github.run_id}}_ATTEMPT.${{github.run_attempt}} with: name: ${{ env.MY_STEP_VAR }} - path: output.zip + path: tests/testing-results retention-days: 7 - run: echo "This job's status is ${{ job.status }}." @@ -202,19 +197,14 @@ jobs: working-directory: ${{ github.workspace }}/tests run: ./main.py run --uid SuiteUID:tests/gem5/gem5_library_example_tests/test_gem5_library_examples.py:test-${{ matrix.test-type }} --length=long --skip-build -vv - - name: create zip of results - if: success() || failure() - run: | - apt-get -y install zip - zip -r output.zip tests/testing-results - - name: upload zip + - name: upload results if: success() || failure() uses: actions/upload-artifact@v4 env: MY_STEP_VAR: ${{ matrix.test-type }}_COMMIT.${{github.sha}}_RUN.${{github.run_id}}_ATTEMPT.${{github.run_attempt}} with: name: ${{ env.MY_STEP_VAR }} - path: output.zip + path: tests/testing-results retention-days: 7 - run: echo "This job's status is ${{ job.status }}." diff --git a/.github/workflows/weekly-tests.yaml b/.github/workflows/weekly-tests.yaml index 3773557504..41f935bf22 100644 --- a/.github/workflows/weekly-tests.yaml +++ b/.github/workflows/weekly-tests.yaml @@ -139,19 +139,14 @@ jobs: - name: very-long ${{ matrix.test-type }} working-directory: ${{ github.workspace }}/tests run: ./main.py run gem5/${{ matrix.test-type }} --length very-long --skip-build -vv - - name: create zip of results - if: success() || failure() - run: | - apt-get -y install zip - zip -r output.zip tests/testing-results - - name: upload zip + - name: upload results if: success() || failure() uses: actions/upload-artifact@v4 env: MY_STEP_VAR: ${{ matrix.test-type }}_COMMIT.${{github.sha}}_RUN.${{github.run_id}}_ATTEMPT.${{github.run_attempt}} with: name: ${{ env.MY_STEP_VAR }} - path: output.zip + path: tests/testing-results retention-days: 7 - run: echo "This job's status is ${{ job.status }}."