Skip to content

Cleaning

Cleaning #7

name: Run local tests
on:
pull_request:
branches:
- main
# Allows manual run from the Actions tab
workflow_dispatch:
# Allows re-use in other workflows
workflow_call:
jobs:
run-tests:
name: Run tests
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 8
matrix:
os: [ubuntu-latest, windows-latest]
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
steps:
- name: Checkout repo
uses: actions/checkout@v6
- name: Setup python ${{ matrix.python-version }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install .[test]
- name: Run unit tests
run: |
cd tests
python -m pytest test_download_from_package.py
python -m pytest --dist loadfile -v --junitxml="test_results.xml" -m unit
- name: Run container tests
if: runner.os == 'Linux'
run: |
cd tests
python -m pytest test_download_from_package.py
python -m pytest --dist loadfile -v --junitxml="test_results.xml" -m container
- name: Upload emodpy test results
uses: actions/upload-artifact@v6
if: failure()
with:
name: emodpy_test_results
path: tests/test_results.xml