feat(ds-flow): Phase 5.3 — CI 串联三道闸 + golden 扩全量
.gitea/workflows/ci.yml: - 新增 ds-flow job:原型校验(check-ds)+ 跨端同源(check-l1-sync)+ Flutter 颜色单源(check_ds_code --strict),均 node:20 容器零依赖跑。 - golden job 从「components+auth」扩到全量 test/golden(desktop/tablet 现均绿, 含 CJK 真渲染 + tablet zh/en 矩阵)。 - codegen 零 diff(codegen-drift job)已有。 至此四道静态闸 + golden 全部进 CI 硬闸(「规则没上闸=没有规则」)。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+18
-2
@@ -161,6 +161,22 @@ jobs:
|
|||||||
node:20 \
|
node:20 \
|
||||||
bash ci/check-codegen-drift.sh
|
bash ci/check-codegen-drift.sh
|
||||||
|
|
||||||
|
ds-flow:
|
||||||
|
name: DS-flow — 原型/跨端同源/代码色单源闸
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: 原型校验(check-ds)
|
||||||
|
run: docker run --rm -v "$PWD:/repo" -w /repo node:20 node design/prototype/tools/check-ds.mjs
|
||||||
|
|
||||||
|
- name: 跨端同源(check-l1-sync)
|
||||||
|
run: docker run --rm -v "$PWD:/repo" -w /repo node:20 node tools/check-l1-sync.mjs
|
||||||
|
|
||||||
|
- name: Flutter 颜色单源(check_ds_code --strict)
|
||||||
|
run: docker run --rm -v "$PWD/client:/app" -w /app node:20 node tool/check_ds_code.mjs --strict
|
||||||
|
|
||||||
# ── Job 7: Go 服务端(build + test:含契约快照 + sqlite 真库,跳过 integration)──
|
# ── Job 7: Go 服务端(build + test:含契约快照 + sqlite 真库,跳过 integration)──
|
||||||
# 此前 server 测试未进 CI;契约快照(支柱 2)等需在此守门。integration 测试走
|
# 此前 server 测试未进 CI;契约快照(支柱 2)等需在此守门。integration 测试走
|
||||||
# -tags integration(需 docker 起 mysql/redis),见 go-integration job。
|
# -tags integration(需 docker 起 mysql/redis),见 go-integration job。
|
||||||
@@ -230,7 +246,7 @@ jobs:
|
|||||||
# Linux 权威基线(scripts/update-goldens.sh 生成;mac 渲染不一致故钉死 Linux 容器)。
|
# Linux 权威基线(scripts/update-goldens.sh 生成;mac 渲染不一致故钉死 Linux 容器)。
|
||||||
# tablet/desktop-stats golden 与 stats-overhaul 工作区耦合,待其合并后并入本 job。
|
# tablet/desktop-stats golden 与 stats-overhaul 工作区耦合,待其合并后并入本 job。
|
||||||
golden:
|
golden:
|
||||||
name: Golden — 视觉回归 (components + auth)
|
name: Golden — 视觉回归 (全量:components/auth/desktop/tablet)
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
@@ -243,4 +259,4 @@ jobs:
|
|||||||
-v "$PWD/client:/app" -w /app \
|
-v "$PWD/client:/app" -w /app \
|
||||||
-v "$HOME/.cache/pangolin-ci/pubcache:/root/.pub-cache" \
|
-v "$HOME/.cache/pangolin-ci/pubcache:/root/.pub-cache" \
|
||||||
ghcr.io/cirruslabs/flutter:stable \
|
ghcr.io/cirruslabs/flutter:stable \
|
||||||
bash -c "flutter pub get && flutter test test/golden/components_golden_test.dart test/golden/auth_redesign_golden_test.dart"
|
bash -c "flutter pub get && flutter test test/golden"
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ Flutter 已很干净(UI 层零裸 hex),只需收尾。
|
|||||||
- Flutter `client/tool/check_ds_code.mjs`(照搬 jiu,含 `--changed` 供 pre-commit):禁 `Color(0x..)`/裸 `Colors.x`
|
- Flutter `client/tool/check_ds_code.mjs`(照搬 jiu,含 `--changed` 供 pre-commit):禁 `Color(0x..)`/裸 `Colors.x`
|
||||||
- Web hex 扫描并入 `check-l1-sync.mjs` ④
|
- Web hex 扫描并入 `check-l1-sync.mjs` ④
|
||||||
- [x] 5.2 原型校验闸 `design/prototype/tools/check-ds.mjs`(照搬 jiu 12 道,按 pangolin 断点/主题裁剪)
|
- [x] 5.2 原型校验闸 `design/prototype/tools/check-ds.mjs`(照搬 jiu 12 道,按 pangolin 断点/主题裁剪)
|
||||||
- [ ] 5.3 CI 串起来(`.gitea/workflows/ci.yml` 增补):
|
- [x] 5.3 CI 串起来(`.gitea/workflows/ci.yml` 增补):
|
||||||
原型校验 → 跨端同源 → 代码色单源 → codegen 零 diff(已有)→ 测试含 golden(已有,补 mobile+主题)
|
原型校验 → 跨端同源 → 代码色单源 → codegen 零 diff(已有)→ 测试含 golden(已有,补 mobile+主题)
|
||||||
- [ ] 5.4 启用 pre-commit:`ci/install-hooks.sh` 纳入 onboarding 文档 + CLAUDE.md,
|
- [ ] 5.4 启用 pre-commit:`ci/install-hooks.sh` 纳入 onboarding 文档 + CLAUDE.md,
|
||||||
`.githooks/pre-commit` 增挂 `check-ds --changed`(只在动了 `design/prototype/` 时跑,轻量条件触发)
|
`.githooks/pre-commit` 增挂 `check-ds --changed`(只在动了 `design/prototype/` 时跑,轻量条件触发)
|
||||||
|
|||||||
Reference in New Issue
Block a user