system-prompts-and-models-o.../.github/workflows/dealix-ci.yml

73 lines
2.1 KiB
YAML

# Runs when salesflow-saas/ changes (monorepo root)
name: Dealix CI
on:
push:
branches: [main]
paths:
- "salesflow-saas/**"
pull_request:
branches: [main]
paths:
- "salesflow-saas/**"
jobs:
backend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: salesflow-saas/backend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Monorepo constitution preflight (repo root)
working-directory: .
run: python scripts/architecture_brief.py
- name: Install dependencies
run: |
pip install -r requirements.txt -r requirements-dev.txt
- name: Pytest (full suite + launch scenarios)
env:
DATABASE_URL: sqlite+aiosqlite:///./ci_dealix.db
DEALIX_INTERNAL_API_TOKEN: ""
run: python -m pytest tests -q --tb=line
- name: OpenAPI vs frontend API paths
working-directory: salesflow-saas
env:
DATABASE_URL: sqlite+aiosqlite:///./openapi_verify.db
DEALIX_INTERNAL_API_TOKEN: ""
run: python scripts/verify_frontend_openapi_paths.py
- name: Go-live gate (in-process CLI)
working-directory: salesflow-saas
env:
DATABASE_URL: sqlite+aiosqlite:///./go_live_gate_ci.db
DEALIX_INTERNAL_API_TOKEN: ""
run: python scripts/check_go_live_gate.py
frontend:
runs-on: ubuntu-latest
defaults:
run:
working-directory: salesflow-saas/frontend
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "22"
cache: npm
cache-dependency-path: salesflow-saas/frontend/package-lock.json
- name: Install
run: npm ci
- name: Lint
run: npm run lint
- name: Build
run: npm run build
- name: Install Playwright Chromium
run: npx playwright install --with-deps chromium
- name: E2E smoke (auth shell)
env:
CI: true
run: npm run test:e2e