Repository navigation
131 lines (107 loc) · 4.34 KB
/
Copy pathci.yml
File metadata and controls
131 lines (107 loc) · 4.34 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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
name: CI
on:
push:
branches: [main]
pull_request:
jobs:
build-and-test:
name: 构建与测试
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # SourceLink 与 EmbedUntrackedSources 需要完整历史
- uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.0.x
- name: 还原
run: dotnet restore CodeWF.Toolkit.slnx
- name: 验证 T4 国际化资源映射
shell: pwsh
run: ./scripts/sync_localization_keys.ps1 -Check
- name: 构建
run: dotnet build CodeWF.Toolkit.slnx -c Release --no-restore
- name: 测试
run: dotnet test CodeWF.Toolkit.slnx -c Release --no-build
aot-smoke:
name: AOT 冒烟(Demo 发布与运行)
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.0.x
- name: AOT 发布 Demo
run: dotnet publish demo/CodeWF.Toolkit.Demo/CodeWF.Toolkit.Demo.csproj -c Release -r win-x64 -p:PublishAot=true -o artifacts/aot-smoke
- name: 运行冒烟演示
run: artifacts\aot-smoke\CodeWF.Toolkit.Demo.exe --smoke
- name: AOT 发布国际化与更新流程验证
run: dotnet publish tests/CodeWF.Toolkit.AotSmoke/CodeWF.Toolkit.AotSmoke.csproj -c Release -r win-x64 -o artifacts/aot-library-smoke
- name: 验证嵌入资源、更新缓存与校验下载
run: artifacts\aot-library-smoke\CodeWF.Toolkit.AotSmoke.exe
aot-smoke-avalonia:
name: AOT 冒烟(Avalonia 演示台发布与运行)
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: 10.0.x
- name: AOT 发布 Avalonia 演示台
shell: pwsh
run: pwsh scripts/publish_toolkit_demo.ps1 -RuntimeIdentifier win-x64
# 冒烟现在逐页构建并逐色板渲染,退出码可作门禁(不再 continue-on-error)
- name: 运行冒烟演示
run: artifacts\publish\win-x64\CodeWF.Toolkit.Demo.Avalonia\CodeWF.Toolkit.Demo.Avalonia.exe --smoke
- name: AOT 发布离屏目录验证
run: dotnet publish scripts/demo-verification/DemoVerification.csproj -c Release -r win-x64 -p:PublishAot=true -p:IlcGenerateCompleteTypeMetadata=true -p:IlcTrimMetadata=false -p:IlcSingleThreaded=true -o artifacts/aot-demo-verification
- name: 验证目录渲染、帮助类运行与库语言切换
run: artifacts\aot-demo-verification\DemoVerification.exe
- name: 验证原生演示台与通知计数配色
run: artifacts\aot-demo-verification\DemoVerification.exe --palette-audit artifacts/native-palette
prototype-audit:
name: 原型路由与语言审计
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 24
cache: npm
cache-dependency-path: design/tests/package-lock.json
- name: 验证目录生成物
shell: pwsh
run: ./scripts/sync_design_catalog.ps1 -Check
- name: 安装审计依赖
working-directory: design/tests
run: npm ci
- name: 安装 Chromium
working-directory: design/tests
run: npx playwright install --with-deps chromium
- name: 检查路由、语言和导航
working-directory: design/tests
run: npm test
- name: 检查原生参数契约与交互效果
working-directory: design/tests
run: node audit-native-parameters.cjs
- uses: actions/upload-artifact@v4
if: failure()
with:
name: prototype-audit-failure
path: design/tests/artifacts/
packaging-contract:
name: 安装包布局与失败传播
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: 验证 macOS 打包契约
run: bash scripts/tests/macos_packaging_test.sh
- name: 验证单文件原型跨平台换行一致性
shell: pwsh
run: ./scripts/tests/prototype_newlines_test.ps1
- name: 验证五平台安装包门禁
shell: pwsh
run: ./scripts/tests/release_installers_test.ps1
- name: 验证 Linux 安装结构与失败传播
shell: pwsh
run: ./scripts/tests/linux_packaging_test.ps1