test: add taro h5 release manifest gate

This commit is contained in:
Codex
2026-07-01 05:27:18 +08:00
parent c73722202e
commit ced371309c
9 changed files with 557 additions and 4 deletions

View File

@@ -25,10 +25,11 @@ H5 入口模板在 `src/index.html`。构建后每个目录都必须有 `index.h
```bash
npm run smoke:taro:h5
npm run manifest:taro:h5
node scripts/taro-h5-release-guardrails-test.js --require-dist
```
`smoke:taro:h5` 会用临时静态服务器验证三套 H5 的 `index.html`、JS/CSS 资源、history fallback、公开 `runtime-config.json``/api/tenant/resolve` 契约。发布守卫会扫描三套 H5 产物和运行配置边界,阻断旧 PocketBase 引用、`x-user-id`、平台本地 key、数据库连接串和服务端密钥形态进入前端产物。正式部署时仍需要在每个 H5 目录根部放置对应的 `runtime-config.json`
`smoke:taro:h5` 会用临时静态服务器验证三套 H5 的 `index.html`、JS/CSS 资源、history fallback、公开 `runtime-config.json``/api/tenant/resolve` 契约。`manifest:taro:h5` 会输出三套 H5 的部署清单,包含构建命令、发布目录、入口路由、资源数量、`index.html` hash 和 runtime-config 状态,方便上线前核对 Web 根目录。发布守卫会扫描三套 H5 产物和运行配置边界,阻断旧 PocketBase 引用、`x-user-id`、平台本地 key、数据库连接串和服务端密钥形态进入前端产物。正式部署时仍需要在每个 H5 目录根部放置对应的 `runtime-config.json`
## 当前学生端页面