Skip to content

WIP: Add ci workflow to run unit tests on pr or merge into main branches S… #4

WIP: Add ci workflow to run unit tests on pr or merge into main branches S…

WIP: Add ci workflow to run unit tests on pr or merge into main branches S… #4

Workflow file for this run

name: CI
on:
pull_request:
types: [opened, synchronize, reopened]
push:
branches:
- trunk
- 'fix*'
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.8", "3.11"]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set Up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Set PYTHONPATH
run: |
echo "PYTHONPATH=$(pwd)/scm" >> $GITHUB_ENV
- name: Display Python Version
run: python -c "import sys; print(sys.version)"
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install pytest
pip install coverage
- name: Run Unit Tests
run: |
coverage run -m pytest unit_tests
- name: Evaluate Coverage
run: coverage report --omit="unit_tests/*" -i --fail-under=30