|
13 | 13 | name: 'Core / Unit Test Pipeline' |
14 | 14 | runs-on: ubuntu-latest |
15 | 15 | timeout-minutes: 20 |
16 | | - permissions: |
17 | | - # For publishing results |
18 | | - checks: write |
19 | 16 |
|
20 | 17 | # Run this test for different Python versions |
21 | 18 | strategy: |
@@ -53,21 +50,44 @@ jobs: |
53 | 50 | run: | |
54 | 51 | make unit_test |
55 | 52 | - |
56 | | - name: Publish Test Results |
57 | | - uses: EnricoMi/publish-unit-test-result-action@v2 |
58 | | - if: always() |
| 53 | + name: Upload Test Reports |
| 54 | + if: (!cancelled()) |
| 55 | + uses: actions/upload-artifact@v6 |
59 | 56 | with: |
60 | | - junit_files: tests_xml/tests.xml |
61 | | - check_name: "Core / Unit Test Results (${{ matrix.python-version }})" |
62 | | - comment_mode: "off" |
| 57 | + name: test-results-python-${{ matrix.python-version }} |
| 58 | + path: tests_xml/tests.xml |
63 | 59 | - |
64 | 60 | name: Upload Coverage Reports |
65 | | - if: always() |
66 | | - uses: actions/upload-artifact@v4 |
| 61 | + if: (!cancelled()) |
| 62 | + uses: actions/upload-artifact@v6 |
67 | 63 | with: |
68 | 64 | name: coverage-report-core-unittests-py${{ matrix.python-version }} |
69 | 65 | path: coverage/ |
70 | 66 |
|
| 67 | + publish-test-results: |
| 68 | + name: "Tests Results" |
| 69 | + needs: build-and-test |
| 70 | + runs-on: ubuntu-latest |
| 71 | + permissions: |
| 72 | + # For publishing results |
| 73 | + checks: write |
| 74 | + |
| 75 | + if: (!cancelled()) |
| 76 | + steps: |
| 77 | + - |
| 78 | + name: Download Artifacts |
| 79 | + uses: actions/download-artifact@v7 |
| 80 | + with: |
| 81 | + path: artifacts |
| 82 | + pattern: test-results-python-* |
| 83 | + - |
| 84 | + name: Publish Test Results |
| 85 | + uses: EnricoMi/publish-unit-test-result-action@v2 |
| 86 | + with: |
| 87 | + junit_files: artifacts/**/*.xml |
| 88 | + check_name: "Core / Unit Test" |
| 89 | + comment_mode: "off" |
| 90 | + |
71 | 91 | test-petals: |
72 | 92 | name: Petals Compatibility |
73 | 93 | uses: CLIMADA-project/climada_petals/.github/workflows/testing.yml@develop |
|
0 commit comments