MotorSignal-App/.github/workflows/backend-ci.yml

46 lines
1.1 KiB
YAML

name: MotorSignal Backend CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: backend-ci-${{ github.ref }}
cancel-in-progress: true
jobs:
backend-api-tests:
name: Backend API tests
runs-on: ubuntu-latest
defaults:
run:
working-directory: backend/motorsignal_api
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: 'pip'
cache-dependency-path: backend/motorsignal_api/requirements.lock
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.lock pytest httpx
- name: Run Firebase Auth signature and claims tests
run: python tests/test_firebase_auth.py
- name: Run isolated API and Operations unit tests
run: |
pytest tests/test_ops_support.py tests/test_ops_incidents.py tests/test_legacy_admin_retirement.py -v