diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index caf318af8..2f48e67b5 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -130,16 +130,9 @@ jobs: run: | mv .github/.coveragerc . - - name: remove slashes from test name - run: | - test=$(echo ${{ matrix.test }} | sed 's/\//__/g') - echo "test=${test}" >> $GITHUB_ENV - - name: Test with pytest run: | - python3 -m pytest tests/${{matrix.test}} --color=yes --cov --cov-data-file=.coverage.${{ env.test }} --durations=0 && exit_code=0|| exit_code=$? - echo "Current directory contents:" - ls -la + python3 -m pytest tests/${{matrix.test}} --color=yes --cov --durations=0 && exit_code=0|| exit_code=$? # don't fail if no tests were collected, e.g. for test_licence.py if [ "${exit_code}" -eq 5 ]; then echo "No tests were collected" @@ -149,18 +142,25 @@ jobs: exit 1 fi + - name: remove slashes from test name + run: | + test=$(echo ${{ matrix.test }} | sed 's/\//__/g') + echo "test=${test}" >> $GITHUB_ENV + - name: Store snapshot report uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 if: always() with: + include-hidden-files: true name: Snapshot Report ${{ env.test }} path: ./snapshot_report.html - name: Upload coverage uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4 with: + include-hidden-files: true name: coverage_${{ env.test }} - path: .coverage.${{ env.test }} + path: .coverage coverage: needs: test