Skip to content

update

update #176

Workflow file for this run

name: pytest
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
pyTestCov:
strategy:
matrix:
python-version: [3.9, '3.10', '3.11', '3.12']
runs-on: ubuntu-latest
steps:
- name: Python Setup
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Checkout Source
uses: actions/checkout@v2
- name: Setup Conda Environment
uses: conda-incubator/setup-miniconda@v3
with:
miniforge-version: latest
python-version: ${{ matrix.python-version }}
activate-environment: test-environment
channels: conda-forge
conda-remove-defaults: true
channel-priority: strict
- name: Update environment
run: mamba env update -n test-environment -f continuous_integration/environment.yaml
if: steps.cache.outputs.cache-hit != 'true'
- name: Run Tests
run: python3 -m pytest -v --cov=./ --cov-report=xml --timeout=60
- name: Upload to Codecov
uses: codecov/codecov-action@v2
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos