Add API smoke tests and GitHub Actions CI (web build verification) #1
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| api-tests: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install API dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt pytest httpx | |
| - name: Run API smoke tests | |
| run: PYTHONPATH=apps/dashboard_api pytest -q apps/dashboard_api/tests | |
| web-build: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: apps/dashboard_web | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: apps/dashboard_web/package-lock.json | |
| - name: Install Web dependencies | |
| run: npm ci | |
| - name: Build Web app | |
| run: npm run build |