Skip to content

moved conf file back to source #164

moved conf file back to source

moved conf file back to source #164

Workflow file for this run

name: CI workflow
on:
push:
# Currently runs on all branches
pull_request:
# Currently runs on all branches
workflow_dispatch:
jobs:
build:
# Test three different OS
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.10", "3.11","3.12"]
steps:
- uses: actions/checkout@v2 # Check out code in repo onto the runner
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest pytest-cov
pip install .
# ^ Should look for setup.py file
- name: Lint with flake8
run: |
flake8 . --exit-zero --max-complexity=10 --max-line-length=127
# Output error in CI workflow log, but do not fail the workflow if there are linting errors
# max-complexity=10 specifies the max number of paths through a function before a linting error is returned
# max-line-length=127 sets the maximum allowed line length before a linting error is returned
- name: Run unit tests with coverage reporting
run: |
pytest --cov=./pkmodel --cov-report=xml
cat coverage.xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
files: coverage.xml