-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgithub-actions-ci.yml
More file actions
executable file
·95 lines (81 loc) · 2.45 KB
/
github-actions-ci.yml
File metadata and controls
executable file
·95 lines (81 loc) · 2.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
name: CI
on:
push:
branches:
- main
- master
- develop
- develop/**
pull_request:
jobs:
backend:
runs-on: ubuntu-latest
services:
postgres:
image: postgres:16
env:
POSTGRES_DB: app_local
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
ports:
- 5432:5432
options: >-
--health-cmd "pg_isready -U postgres -d app_local"
--health-interval 5s
--health-timeout 5s
--health-retries 20
env:
APP_PG_HOST: 127.0.0.1
APP_PG_PORT: 5432
APP_PG_DATABASE: app_local
APP_PG_USER: postgres
APP_PG_PASSWORD: postgres
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install backend dependencies
run: python -m pip install --upgrade pip && python -m pip install -r backend/requirements.txt
- name: Backend compile
run: |
python -m py_compile \
backend/main.py \
backend/scripts/scaffold_backend_module.py \
scripts/scaffold_frontend_module.py \
scripts/scaffold_fullstack_module.py \
backend/tests/test_backend_scaffold.py \
backend/tests/test_frontend_scaffold.py \
backend/tests/test_fullstack_scaffold.py \
backend/tests/test_http_smoke.py \
backend/tests/test_menu_registry.py \
backend/tests/test_router_registry.py
- name: Backend tests
run: |
python -m unittest \
backend.tests.test_frontend_scaffold \
backend.tests.test_menu_registry \
backend.tests.test_modular_routes \
backend.tests.test_backend_scaffold \
backend.tests.test_router_registry \
backend.tests.test_fullstack_scaffold \
-v
- name: Backend HTTP smoke
run: python -m unittest backend.tests.test_http_smoke -v
frontend:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '22'
- name: Install frontend dependencies
run: npm install --no-audit --no-fund
- name: Type check
run: npm run type-check
- name: Build
run: npm run build-only