Skip to content

Try debuggin CI

Try debuggin CI #301

Workflow file for this run

---
name: Test
on:
pull_request:
push:
branches:
- master
- dev1
- "!gh-pages"
env:
IS_CI: 'true'
jobs:
bundled:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: ['ubuntu-latest']
python-version: ['3.9', '3.10', '3.11']
jobtype: ['test']
include:
- os: 'ubuntu-latest'
python-version: '3.10'
jobtype: 'lint'
- os: 'ubuntu-latest'
python-version: '3.10'
jobtype: 'coverage'
- os: 'macos-latest'
python-version: '3.10'
jobtype: 'test'
env:
JOBTYPE: ${{ matrix.jobtype }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: 'setup.py'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[dev]
pip install coveralls
- name: Run tests
run: |
if [[ "$JOBTYPE" == "lint" ]]; then
# Run flake8 via pre-commit instead.
#- flake8 . # Use --exit-zero to ignore failure
pre-commit install
pre-commit run --all-files
elif [[ "$JOBTYPE" == "coverage" ]]; then
pytest tests --ignore=dapper/mods/QG --cov=dapper --cov-report term-missing
else
pytest tests
fi
- name: Export debug info init
uses: actions/upload-artifact@v2
with:
name: test-results
path: init.txt
- name: Export debug info resample
uses: actions/upload-artifact@v2
with:
name: test-results
path: resample.txt
- name: Publish coverage to coveralls.io
if: ${{ env.JOBTYPE == 'coverage' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: coveralls --service=github
conda:
defaults:
run:
shell: bash -el {0}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: ['ubuntu-latest']
python-version: ['3.9', '3.10', '3.11']
include:
- os: 'macos-latest'
python-version: '3.10'
- os: 'windows-latest'
python-version: '3.9'
steps:
- uses: actions/checkout@v3
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: pip install -e .[dev]
- name: Run tests
run: |
which python
pytest tests