Bump actions/upload-artifact from 3 to 4 #48
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: pytest | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
pytest: | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.8' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install . | |
- name: Test with pytest | |
run: | | |
pytest test \ | |
--doctest-modules \ | |
--junitxml=junit/test-results.xml | |
- name: Upload pytest test results | |
uses: actions/upload-artifact@v4 | |
with: | |
name: test-results.xml | |
path: junit/test-results.xml | |
if-no-files-found: error | |
# Use always() to always run this step to publish test results when | |
# there are test failures | |
if: ${{ always() }} |