raymuz's picture
Update audited Customer Churn models and app
422809f verified
Raw History Blame Contribute Delete
799 Bytes
name: CI — Model and API smoke tests
on:
push:
pull_request:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.13'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt 'pytest>=8,<10' 'httpx>=0.27,<1'
- name: Validate stored model versions
run: |
python -c "import json,sklearn,xgboost; m=json.load(open('model_metadata.json')); assert m['sklearn_version']==sklearn.__version__; assert m['xgboost_version']==xgboost.__version__"
- name: Compile and test REST API
run: |
python -m py_compile app.py train.py
python -m pytest -q tests