61 lines
1.4 KiB
YAML
61 lines
1.4 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- "**"
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
test-and-quality:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.12"
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install --upgrade pip
|
|
pip install -r requirements.txt
|
|
pip install ruff
|
|
|
|
- name: Lint
|
|
run: ruff check .
|
|
|
|
- name: Django checks
|
|
run: |
|
|
python manage.py check
|
|
python scripts/check_i18n_drift.py
|
|
python manage.py test lobby fupogfakta -v 1
|
|
|
|
- name: Setup Node
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "22"
|
|
|
|
- name: Install shared frontend dependencies
|
|
run: npm ci --prefix frontend
|
|
|
|
- name: Shared frontend checks
|
|
run: |
|
|
npm --prefix frontend test
|
|
npm --prefix frontend run build
|
|
|
|
- name: Install SPA dependencies
|
|
run: |
|
|
npm ci --prefix frontend/angular
|
|
node -e "require('./frontend/angular/node_modules/rollup/dist/native.js')" \
|
|
|| npm install --prefix frontend/angular
|
|
|
|
- name: SPA Angular checks
|
|
run: |
|
|
npm --prefix frontend/angular test
|
|
npm --prefix frontend/angular run build
|