Skip to content

Add workflows

Add workflows #1

Workflow file for this run

name: tests
on:
push:
pull_request:
jobs:
build:
name: Tests on ${{ matrix.os }} - ${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ['3.7', '3.11', 'pypy-3.9']
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install base dependencies
run: pip install numpy matplotlib
# - name: Python Test
# run: pytest
- name: Install scipy
run: pip install scipy
- name: Python Test
run: pytest
- name: Python Test with Coverage
if: contains(matrix.os, 'ubuntu')
run: |
pip install pytest-cov
pytest --cov=matspy --cov-report term --cov-report=xml
- name: Upload Coverage to Codecov
if: ${{ contains(matrix.os, 'ubuntu') && !contains(matrix.python-version, 'pypy') }}
uses: codecov/codecov-action@v3
with:
gcov: true
gcov_include: matspy/*