@pzy560117/opentest 0.1.12 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/assets/manifest.json
CHANGED
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: opentest
|
|
3
|
-
description: "OpenTest router
|
|
3
|
+
description: "OpenTest router."
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# OpenTest
|
|
7
7
|
|
|
8
|
-
OpenTest
|
|
8
|
+
OpenTest is the single user entry. The AI routes phases and surface adapters.
|
|
9
9
|
|
|
10
10
|
## Required references
|
|
11
11
|
|
|
12
12
|
- `opentest/references/command-routing.md`
|
|
13
13
|
- `opentest/references/lifecycle.md`
|
|
14
14
|
- `opentest/references/complete-testing-workflow.md`
|
|
15
|
+
- `opentest/references/test-surfaces.md`
|
|
15
16
|
|
|
16
17
|
## Bootstrap
|
|
17
18
|
|
|
@@ -22,12 +23,12 @@ OPENTEST_GUARD="${OPENTEST_GUARD:-$(find "${OPENTEST_SEARCH_ROOTS[@]}" -path '*/
|
|
|
22
23
|
OPENTEST_DETECT="${OPENTEST_DETECT:-$(find "${OPENTEST_SEARCH_ROOTS[@]}" -path '*/opentest/scripts/opentest-detect.sh' -type f -print -quit 2>/dev/null)}"
|
|
23
24
|
```
|
|
24
25
|
|
|
25
|
-
|
|
26
|
+
Stop if scripts are missing.
|
|
26
27
|
|
|
27
28
|
## Route
|
|
28
29
|
|
|
29
30
|
1. If `.opentest.yaml` is missing, run `bash "$OPENTEST_STATE" init`.
|
|
30
31
|
2. Run `bash "$OPENTEST_STATE" check` and `bash "$OPENTEST_DETECT" summary`.
|
|
31
|
-
3.
|
|
32
|
-
4.
|
|
33
|
-
5.
|
|
32
|
+
3. Dispatch by `phase` to `opentest-plan`, `opentest-author`, `opentest-run`, `opentest-accept`, `opentest-verify`, `opentest-heal`, or `opentest-archive`.
|
|
33
|
+
4. `plan/run/accept` choose adapters from matrix surface: `web-browser` -> `opentest-web-browser`, `android-app` -> `opentest-android-app`, `desktop-gui` -> `opentest-desktop-gui`, `api` -> `opentest-api`.
|
|
34
|
+
5. Ask only when surface cannot be inferred. Use installed skill language.
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: opentest
|
|
3
|
-
description: "OpenTest
|
|
3
|
+
description: "OpenTest 路由:状态检测、阶段分发和执行面 adapter 选择。"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# OpenTest
|
|
7
7
|
|
|
8
|
-
OpenTest
|
|
8
|
+
OpenTest 把需求转成测试证据生命周期。用户只触发 OpenTest;AI 自动选择阶段 skill 和执行面 adapter。
|
|
9
9
|
|
|
10
10
|
## 必读引用
|
|
11
11
|
|
|
12
12
|
- `opentest/references/command-routing.md`
|
|
13
13
|
- `opentest/references/lifecycle.md`
|
|
14
14
|
- `opentest/references/complete-testing-workflow.md`
|
|
15
|
+
- `opentest/references/test-surfaces.md`
|
|
15
16
|
|
|
16
17
|
## 启动
|
|
17
18
|
|
|
@@ -28,6 +29,6 @@ OPENTEST_DETECT="${OPENTEST_DETECT:-$(find "${OPENTEST_SEARCH_ROOTS[@]}" -path '
|
|
|
28
29
|
|
|
29
30
|
1. 若 `.opentest.yaml` 不存在,运行 `bash "$OPENTEST_STATE" init`。
|
|
30
31
|
2. 运行 `bash "$OPENTEST_STATE" check` 和 `bash "$OPENTEST_DETECT" summary`。
|
|
31
|
-
3.
|
|
32
|
-
4.
|
|
33
|
-
5.
|
|
32
|
+
3. 按 `phase` 分发到 `opentest-plan`、`opentest-author`、`opentest-run`、`opentest-accept`、`opentest-verify`、`opentest-heal` 或 `opentest-archive`。
|
|
33
|
+
4. `plan/run/accept` 按矩阵执行面自动选择 adapter:`web-browser` -> `opentest-web-browser`,`android-app` -> `opentest-android-app`,`desktop-gui` -> `opentest-desktop-gui`,`api` -> `opentest-api`。
|
|
34
|
+
5. 除非无法推断执行面,不要让用户手动选择 adapter。使用已安装的 skill 语言。
|
package/package.json
CHANGED
package/scripts/smoke-test.js
CHANGED
|
@@ -222,6 +222,8 @@ function assertRequirementFirstAcceptanceContracts() {
|
|
|
222
222
|
|
|
223
223
|
function assertTestSurfaceContracts() {
|
|
224
224
|
const manifestText = readFileSync('assets/manifest.json', 'utf8');
|
|
225
|
+
const englishRouter = readFileSync('assets/skills/opentest/SKILL.md', 'utf8');
|
|
226
|
+
const chineseRouter = readFileSync('assets/skills-zh/opentest/SKILL.md', 'utf8');
|
|
225
227
|
const englishSurfaces = readRequiredText('assets/skills/opentest/references/test-surfaces.md', '[SURFACE] missing English test-surfaces reference');
|
|
226
228
|
const chineseSurfaces = readRequiredText('assets/skills-zh/opentest/references/test-surfaces.md', '[SURFACE] missing Chinese test-surfaces reference');
|
|
227
229
|
const englishMatrixFormat = readFileSync('assets/skills/opentest/references/matrix-format.md', 'utf8');
|
|
@@ -245,6 +247,8 @@ function assertTestSurfaceContracts() {
|
|
|
245
247
|
const surfaces = ['web-browser', 'android-app', 'desktop-gui', 'api'];
|
|
246
248
|
|
|
247
249
|
assert(manifestText.includes('opentest/references/test-surfaces.md'), '[SURFACE] manifest must ship test-surfaces reference');
|
|
250
|
+
assert(englishRouter.includes('single user entry') && englishRouter.includes('matrix surface') && englishRouter.includes('Ask only when') && englishRouter.includes('surface cannot be inferred'), '[SURFACE] English router must keep single-entry automatic adapter routing');
|
|
251
|
+
assert(chineseRouter.includes('用户只触发 OpenTest') && chineseRouter.includes('按矩阵执行面自动选择 adapter') && chineseRouter.includes('不要让用户手动选择 adapter'), '[SURFACE] Chinese router must keep single-entry automatic adapter routing');
|
|
248
252
|
|
|
249
253
|
for (const surface of surfaces) {
|
|
250
254
|
assert(englishSurfaces.includes(surface), `[SURFACE] English test-surfaces missing ${surface}`);
|
|
@@ -253,6 +257,8 @@ function assertTestSurfaceContracts() {
|
|
|
253
257
|
assert(chineseMatrixFormat.includes(surface), `[SURFACE] Chinese matrix-format missing ${surface}`);
|
|
254
258
|
assert(englishMatrix.includes(surface), `[SURFACE] English matrix template missing ${surface}`);
|
|
255
259
|
assert(chineseMatrix.includes(surface), `[SURFACE] Chinese matrix template missing ${surface}`);
|
|
260
|
+
assert(englishRouter.includes(surface), `[SURFACE] English router missing ${surface}`);
|
|
261
|
+
assert(chineseRouter.includes(surface), `[SURFACE] Chinese router missing ${surface}`);
|
|
256
262
|
}
|
|
257
263
|
|
|
258
264
|
assert(englishSurfaces.includes('Do not invent a fifth primary surface'), '[SURFACE] English reference must forbid fifth primary surface');
|