@orion-qa/orion 3.3.0 → 3.4.0
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/.claude/skills/appium/SKILL.md +2 -2
- package/.claude/skills/appium/templates/ci/github-actions-android.yml +1 -1
- package/.claude/skills/appium/templates/ci/github-actions-ios.yml +1 -1
- package/.claude/skills/appium/templates/ci/github-actions-windows.yml +1 -1
- package/.claude/skills/automation-implementation/SKILL.md +1 -1
- package/.claude/skills/automation-strategy/SKILL.md +1 -0
- package/.claude/skills/cicd-integration/SKILL.md +1 -1
- package/.claude/skills/code-review/SKILL.md +1 -1
- package/.claude/skills/code-review/references/pattern-rules.md +1 -0
- package/.claude/skills/csharp/SKILL.md +1 -0
- package/.claude/skills/documentation/SKILL.md +1 -1
- package/.claude/skills/execution/SKILL.md +8 -8
- package/.claude/skills/httpclient/templates/ci/github-actions.yml +2 -2
- package/.claude/skills/java/SKILL.md +1 -0
- package/.claude/skills/javascript/SKILL.md +1 -0
- package/.claude/skills/junit5/SKILL.md +1 -1
- package/.claude/skills/k6/SKILL.md +1 -1
- package/.claude/skills/k6/templates/project/tests/load/products.js +1 -1
- package/.claude/skills/karate/SKILL.md +1 -1
- package/.claude/skills/karate/templates/ci/github-actions.yml +2 -2
- package/.claude/skills/newman/templates/ci/github-actions.yml +2 -2
- package/.claude/skills/newman/templates/collection/src/config/env.js +1 -1
- package/.claude/skills/nunit/SKILL.md +1 -1
- package/.claude/skills/orion/SKILL.md +1 -1
- package/.claude/skills/orion/references/assess-fix.md +1 -1
- package/.claude/skills/orion/references/batch.md +1 -1
- package/.claude/skills/orion/references/capabilities.md +1 -1
- package/.claude/skills/orion/references/conversation.md +3 -3
- package/.claude/skills/orion/references/modes.md +1 -1
- package/.claude/skills/orion/references/plain-language.md +3 -2
- package/.claude/skills/orion/references/recovery-loop.md +2 -2
- package/.claude/skills/orion/references/status-lines.md +4 -4
- package/.claude/skills/orion/references/task-brief.md +1 -1
- package/.claude/skills/orion/scripts/batch_state.mjs +1 -1
- package/.claude/skills/orion/scripts/done_check.mjs +7 -5
- package/.claude/skills/orion/scripts/quiet.mjs +1 -1
- package/.claude/skills/orion/templates/project-context/report.md +2 -2
- package/.claude/skills/pact/SKILL.md +1 -1
- package/.claude/skills/playwright/SKILL.md +2 -2
- package/.claude/skills/playwright/references/electron.md +1 -1
- package/.claude/skills/playwright/templates/README.md +1 -1
- package/.claude/skills/playwright/templates/ci/azure-pipelines.yml +1 -1
- package/.claude/skills/playwright/templates/ci/github-actions-dotnet.yml +2 -2
- package/.claude/skills/playwright/templates/ci/github-actions-javascript.yml +2 -2
- package/.claude/skills/playwright/templates/ci/github-actions-python.yml +2 -2
- package/.claude/skills/playwright/templates/ci/github-actions.yml +1 -1
- package/.claude/skills/playwright/templates/javascript/.prettierignore +6 -0
- package/.claude/skills/playwright/templates/javascript/.prettierrc.json +4 -0
- package/.claude/skills/playwright/templates/javascript/fixtures/index.js +56 -48
- package/.claude/skills/playwright/templates/javascript/package.json +4 -1
- package/.claude/skills/playwright/templates/javascript/pageObjects/basePage.js +5 -1
- package/.claude/skills/playwright/templates/javascript/playwright.config.js +6 -2
- package/.claude/skills/playwright/templates/javascript/reporters/summaryReporter.js +80 -17
- package/.claude/skills/playwright/templates/javascript/resources/desc/signIn.desc.js +10 -3
- package/.claude/skills/playwright/templates/javascript/src/config/env.js +12 -3
- package/.claude/skills/playwright/templates/javascript/src/config/flags.js +3 -1
- package/.claude/skills/playwright/templates/javascript/tests/api/session.spec.js +8 -4
- package/.claude/skills/playwright/templates/javascript/tests/unit/summaryReporter.test.js +30 -6
- package/.claude/skills/playwright/templates/javascript/utils/random.js +3 -1
- package/.claude/skills/playwright/templates/project/.prettierignore +6 -0
- package/.claude/skills/playwright/templates/project/.prettierrc.json +4 -0
- package/.claude/skills/playwright/templates/project/fixtures/index.ts +21 -15
- package/.claude/skills/playwright/templates/project/fixtures/session.ts +9 -2
- package/.claude/skills/playwright/templates/project/package.json +4 -1
- package/.claude/skills/playwright/templates/project/pageObjects/basePage.ts +5 -1
- package/.claude/skills/playwright/templates/project/playwright.config.ts +4 -2
- package/.claude/skills/playwright/templates/project/reporters/summaryReporter.ts +84 -17
- package/.claude/skills/playwright/templates/project/resources/desc/signIn.desc.ts +10 -3
- package/.claude/skills/playwright/templates/project/src/config/env.ts +15 -4
- package/.claude/skills/playwright/templates/project/src/services/apiClient.ts +5 -1
- package/.claude/skills/playwright/templates/project/tests/api/session.spec.ts +8 -4
- package/.claude/skills/playwright/templates/project/tests/unit/summaryReporter.test.ts +30 -6
- package/.claude/skills/playwright/templates/project/utils/formFill.ts +4 -1
- package/.claude/skills/playwright/templates/project/utils/random.ts +3 -1
- package/.claude/skills/playwright/templates/project/utils/redact.ts +4 -1
- package/.claude/skills/pytest/SKILL.md +1 -1
- package/.claude/skills/python/SKILL.md +1 -0
- package/.claude/skills/quality-checks/SKILL.md +1 -1
- package/.claude/skills/requests/templates/ci/github-actions.yml +2 -2
- package/.claude/skills/rest-assured/SKILL.md +2 -2
- package/.claude/skills/rest-assured/templates/ci/github-actions.yml +2 -2
- package/.claude/skills/selenium/SKILL.md +1 -1
- package/.claude/skills/selenium/templates/ci/github-actions-csharp.yml +2 -2
- package/.claude/skills/selenium/templates/ci/github-actions-java.yml +2 -2
- package/.claude/skills/selenium/templates/ci/github-actions-python.yml +2 -2
- package/.claude/skills/self-healing/SKILL.md +1 -1
- package/.claude/skills/test-design/SKILL.md +1 -1
- package/.claude/skills/test-reporting/references/report-levels.md +1 -1
- package/.claude/skills/test-reporting/references/tool-mapping.md +1 -1
- package/.claude/skills/testng/SKILL.md +1 -1
- package/.claude/skills/typescript/SKILL.md +1 -0
- package/.claude/skills/ui-observation/SKILL.md +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/README.md +8 -7
- package/assets/architecture.svg +1 -1
- package/assets/run-flow.svg +1 -1
- package/bin/orion.mjs +6 -6
- package/hosts/gemini-extension/gemini-extension.json +1 -1
- package/package.json +2 -2
|
@@ -21,7 +21,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
21
21
|
|
|
22
22
|
## Run
|
|
23
23
|
- **Server:** the project's way (started by the test setup, a script or CI). Appium 2+ has no bundled drivers: drivers are installed with `appium driver install <driver>@<version>` and their versions recorded in the repo (README or setup script). Installing a driver or app is H10.
|
|
24
|
-
- **Command:** the runner adapter's command (`mvn test -Dtest=<Class>` or `<Class>#<method>`; prefer it to `-Dgroups`, which runs 0 tests and exits green when no group matches). New tests: run
|
|
24
|
+
- **Command:** the runner adapter's command (`mvn test -Dtest=<Class>` or `<Class>#<method>`; prefer it to `-Dgroups`, which runs 0 tests and exits green when no group matches). New tests: run once with retries off (a stability check on request: N runs, all must agree).
|
|
25
25
|
- **Where:** an emulator, simulator, device or desktop session named in the brief (`run_where`) and the app binary named in the run record (path or build artifact and its version). No device → NEEDS_ENVIRONMENT, never "skipped".
|
|
26
26
|
- **Parallel:** each worker needs its own device (`appium:udid`) and its own ports (Android `appium:systemPort`, iOS `appium:wdaLocalPort`).
|
|
27
27
|
- **Evidence on failure:** screenshot, page source (`getPageSource()`), and the device log (Android logcat, iOS syslog) for the failing test.
|
|
@@ -47,7 +47,7 @@ After Gate 4 approves adding one: copy the platform's file from [templates/](tem
|
|
|
47
47
|
Update the locator in the screen object (not the test), with same-target evidence from the page source; replace a sleep with an explicit wait. Never loosen an assertion, never switch to coordinates.
|
|
48
48
|
|
|
49
49
|
## Repeat, data and login (platform rules)
|
|
50
|
-
- New tests:
|
|
50
|
+
- New tests: 1 run, retries off; a stability check on request runs N times and all N must agree.
|
|
51
51
|
- Test data per test with unique values, deleted in teardown even on failure.
|
|
52
52
|
- Credentials only from environment variables or CI secrets; signing certificates, keystores and device-cloud keys only as CI secrets, never in the repo.
|
|
53
53
|
|
|
@@ -21,7 +21,7 @@ on:
|
|
|
21
21
|
required: false
|
|
22
22
|
default: ""
|
|
23
23
|
repeat_each:
|
|
24
|
-
description: "Runs of the selected tests (3 for
|
|
24
|
+
description: "Runs of the selected tests (3 for a stability check; retries are off in the suite)"
|
|
25
25
|
type: choice
|
|
26
26
|
options: ["1", "3"]
|
|
27
27
|
default: "1"
|
|
@@ -20,7 +20,7 @@ on:
|
|
|
20
20
|
required: false
|
|
21
21
|
default: ""
|
|
22
22
|
repeat_each:
|
|
23
|
-
description: "Runs of the selected tests (3 for
|
|
23
|
+
description: "Runs of the selected tests (3 for a stability check; retries are off in the suite)"
|
|
24
24
|
type: choice
|
|
25
25
|
options: ["1", "3"]
|
|
26
26
|
default: "1"
|
|
@@ -11,7 +11,7 @@ on:
|
|
|
11
11
|
required: false
|
|
12
12
|
default: ""
|
|
13
13
|
repeat_each:
|
|
14
|
-
description: "Runs of the selected tests (3 for
|
|
14
|
+
description: "Runs of the selected tests (3 for a stability check; retries are off in the suite)"
|
|
15
15
|
type: choice
|
|
16
16
|
options: ["1", "3"]
|
|
17
17
|
default: "1"
|
|
@@ -36,7 +36,7 @@ description: Writes or modifies automated tests in the project's existing style,
|
|
|
36
36
|
6. **Test data.** Each test creates the data it needs (API or fixture), uses unique values (e.g. a run-scoped suffix), and removes what it created in teardown, even when the test fails. No test depends on another test's data or order. Synthetic values only.
|
|
37
37
|
7. **App login.** Use the project's existing sign-in (helper, fixture, setup project, base class) for the method the UI map's `Login` section records. If none exists, add one per [login-methods.md](../ui-observation/references/login-methods.md) section 5 for that method (form, HTTP auth prompt, SSO, saved session, MFA seed) in the project's pattern, with credentials from environment variables named in `environment-profile.md`; never in code, fixtures or URLs. Sign in once per worker or suite and reuse the session, unless the AC is about sign-in.
|
|
38
38
|
8. **Traceability by id:** every test name carries the case id it implements and its AC (`TS-3 @AC-2 adds the first in-stock product at quantity 1`), or the project's own way of linking (tag, annotation). `@smoke` is not a case id. Every AC in the design is a test, or the result names it with the reason it isn't (Gate 8).
|
|
39
|
-
9. Run the project's compile/lint/type-check command (TypeScript: `npx tsc --noEmit`); a failure is fixed, never skipped. Install the dependencies with the project's lockfile or manifest command (`execution` step 2); in a build's test project that is part of the request, elsewhere the host asks (H10). **The browser goes where the runner looks by default** (`npx playwright install chromium` without `PLAYWRIGHT_BROWSERS_PATH`), or the path is set in the project's own script; never only in a temporary sandbox cache. The run that counts is the project's command from a normal shell with no sandbox browser variable; if the browser isn't on the default path, the result says so.
|
|
39
|
+
9. **Format what you wrote, then check it.** Run the formatter Gate 4 names on the files you added or changed only, never the whole repo (`npx prettier --write <files>`; `ruff format <files>`; `dotnet format --include <files>`; Spotless `mvn spotless:apply` only where the project has it); no formatter named → skip and say so. Then run the project's compile/lint/type-check command (TypeScript: `npx tsc --noEmit`); a failure is fixed, never skipped. Install the dependencies with the project's lockfile or manifest command (`execution` step 2); in a build's test project that is part of the request, elsewhere the host asks (H10). **The browser goes where the runner looks by default** (`npx playwright install chromium` without `PLAYWRIGHT_BROWSERS_PATH`), or the path is set in the project's own script; never only in a temporary sandbox cache. The run that counts is the project's command from a normal shell with no sandbox browser variable; if the browser isn't on the default path, the result says so.
|
|
40
40
|
10. **Fail check (each new test).** Running a test executes project code, so do this only when the brief cites H6 for local or container runs, or a build request's D-nnn (its new tests, in its test project); otherwise write `fail check: not run — no H6`. Prove the test can fail: in your worktree, temporarily change the expected value of its main assertion in place (in the spec itself: no copy of the spec, no second config, no new file in the suite), run that one test with the project's own runner, confirm it fails on that assertion, then restore the file and confirm `git diff` for it matches your intended change only. Record the failing run as a `command` evidence row. Can't run tests here (no runner, Copilot Studio) → write `fail check: not run — <reason>` in Findings; the report carries it as a limitation.
|
|
41
41
|
11. For heals: apply exactly the approved change, nothing else.
|
|
42
42
|
11a. **Keep screenshots out of the repo.** UI story in an existing repo where `git check-ignore -q .ui-map/` fails: add the line `.ui-map/` to the clone's local ignore list, the file `git rev-parse --git-path info/exclude` names, never to the suite's tracked `.gitignore` (the suite's ignore file isn't edited, [work-branch](../orion/references/work-branch.md)). It changes no tracked file, so it isn't in `Changes`.
|
|
@@ -16,6 +16,7 @@ description: "Decides how to automate a requirement: test layer (UI, API, both),
|
|
|
16
16
|
1a. **The layer never lowers coverage.** An observation the requirement or an accepted design places in the UI (what a role sees, a message, a state on screen) stays a UI check; an API check may be added, not swapped in. Replacing one needs the user's yes (`needs_user`). A coverage claim lists, per AC, the observations before and after the change.
|
|
17
17
|
2. Framework: existing one by default. A new project uses the tool, language and style the user confirmed on the setup card (lines 3–4, in the brief); record them with the starter template and don't ask again. Only a change to an existing framework, or a new project with no card answer, → `needs_user` for Gate 4 with a recommendation, at least two alternatives, and for each: fit to the app, team language (from repos and `constraints.md`), CI support for the discovered CI system, and whether an adapter exists in `registry/`. Prefer stacks with an adapter and a starter template; a stack without an adapter also needs H12. Name the patterns from [patterns.md](../automation-implementation/references/patterns.md) the project will use (the card's style: Page Object Model, Hybrid or BDD) ("Choosing" there gives the default per kind of app; API stacks by language and style: [api-styles.md](../automation-implementation/references/api-styles.md)).
|
|
18
18
|
3. Placement: follow the suggested placement and conventions.
|
|
19
|
+
3a. **Formatter.** Use the project's own formatter (Prettier config or a `prettier` key in `package.json`, `biome.json`, `[tool.ruff]` / `[tool.black]` in `pyproject.toml`, `.editorconfig` with `dotnet format`, Spotless in `pom.xml` or `build.gradle`). A new project from a starter: the starter's (Prettier for JavaScript and TypeScript). An existing suite with none: offer one as a row of the Gate 4 table (Prettier for JS/TS, `ruff format` for Python, `dotnet format` for C#, Spotless with google-java-format for Java; `Needs approval: yes`); added only on the user's yes, and only the files the run changes are formatted; untouched files stay as they are.
|
|
19
20
|
4. Reuse: name the helpers to use; justify any new helper.
|
|
20
21
|
5. Data: how each test gets and cleans up data; no shared mutable data.
|
|
21
22
|
6. Environment and execution: which test environment (never prod without H5), which command, and **where tests run**: `ci` (default when a pipeline with `workflow_dispatch`/manual run exists), `container`, or `local`. Running project code on the user's machine is a choice the user approves (H6); say what it runs (install scripts, test code) and with which credentials. Copilot Studio: `ci` only.
|
|
@@ -18,7 +18,7 @@ description: Triggers and monitors the project's CI pipeline for automated tests
|
|
|
18
18
|
- GitHub Actions: `actions_run_trigger` with method `run_workflow` (the workflow needs `workflow_dispatch`).
|
|
19
19
|
- Azure Pipelines: `pipelines_write` with `run_pipeline`.
|
|
20
20
|
- Jenkins, GitLab CI, Bitbucket Pipelines: no trigger connector is bound by default. Return `blocked` / NEEDS_PERMISSION and name the connector folder to enable (`connectors/<system>/`), or run locally with the `execution` skill if the brief allows.
|
|
21
|
-
4. Pass the target **environment name** the pipeline accepts (a test environment from `environment-profile.md`), never a free-form URL. New tests: set the pipeline's repeat input if it has one, else note `repeat: not available in CI` (the
|
|
21
|
+
4. Pass the target **environment name** the pipeline accepts (a test environment from `environment-profile.md`), never a free-form URL. New tests: one run, retries off; for a stability check the user asked for, set the pipeline's repeat input to N if it has one, else note `repeat: not available in CI` (the stability check then needs a local or container run).
|
|
22
22
|
5. Poll status at reasonable intervals until done or the budget runs out (then `partial` with the run link).
|
|
23
23
|
6. Read the result: status, failed jobs, flaky count, test report artifacts, log excerpt. A green job is not a pass on its own: take the executed and skipped counts from the test report and apply the `execution` inventory check (step 7a). A green run with 0 tests, fewer than planned, or new tests skipped is `failed`.
|
|
24
24
|
6a. **No test job yet** (new project): the adapter's `templates/ci/` has a GitHub Actions workflow for each starter template (manual trigger, test-environment choice, a filter that fails when nothing matches, `repeat` 1 or 3, one report per run, artifacts kept 14 days). Adding it is part of the Gate 4 decision; other CI systems get the same steps in their syntax.
|
|
@@ -35,7 +35,7 @@ description: "Reviews an automation diff against the project's own conventions a
|
|
|
35
35
|
# Code review
|
|
36
36
|
| # | Severity | File:line | Finding | Rule (pattern-rules ID, adapter, convention row) |
|
|
37
37
|
## Pattern rules checked
|
|
38
|
-
U1–
|
|
38
|
+
U1–U15, P1–P18: pass · hit (finding #) · n/a (why) · suggestion (project doesn't use the pattern)
|
|
39
39
|
## Reused
|
|
40
40
|
| Helper | Defined at (file:line) | Called at (file:line) |
|
|
41
41
|
## Impacted existing tests
|
|
@@ -19,6 +19,7 @@ One table for the implementer (self-check before returning) and the reviewer (ch
|
|
|
19
19
|
| U12 | Assertions prove an outcome that changed: a quantity or count is asserted against the value read before the action; a dialog, toast or header count only when the walk saw it update and stay updated. A heading or link being visible is not the outcome of an add. | `toHaveValue('1')` with no before-read; `badge`/`count` assertions with no map row showing the update; teardown with no assertion |
|
|
20
20
|
| U13 | One place for the test account: the project's gitignored `.env`; config reads it lazily (importing a page never reads the env file or throws); no second credentials file; nothing outside the project; nothing at the agent-install root. | `throw` at module level in config; `dotenv` loaded in a page; `playwright/.auth/http.json`; paths under `~`, `.config`, `%USERPROFILE%`; `package.json`, `pages/`, `tests/` beside `.claude/` |
|
|
21
21
|
| U14 | Runner config is coherent: no `fullyParallel: true` with `workers: 1`; one worker from the start on a shared staging host; device presets spread before `baseURL`, `httpCredentials`, `storageState`; retries off for the 3 counted runs. | `fullyParallel: true` next to `workers: 1`; `...devices[` after credential keys; `retries:` above 0 in the counted command |
|
|
22
|
+
| U15 | Formatted: where the project or Gate 4 names a formatter, every new or changed file passes its check (`npx prettier --check <files>`, `ruff format --check <files>`, `dotnet format --verify-no-changes --include <files>`); files the run didn't touch are never reformatted. | the formatter's check on the changed files; a diff that reformats untouched code |
|
|
22
23
|
|
|
23
24
|
## P: the project's patterns (blocking for a new project from a starter template and for a project that already uses the pattern; otherwise follow the project and report the row as a non-blocking suggestion)
|
|
24
25
|
| ID | Rule | Look for |
|
|
@@ -20,6 +20,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
20
20
|
|
|
21
21
|
## Check
|
|
22
22
|
- `dotnet build` (warnings as the project configures them).
|
|
23
|
+
- Format the changed files: `dotnet format --include <files>` (part of the .NET SDK; follows `.editorconfig`).
|
|
23
24
|
- `dotnet test --list-tests` shows the new tests are discovered.
|
|
24
25
|
- Playwright browsers after the first build: `pwsh bin/Debug/<tfm>/playwright.ps1 install` (needs PowerShell). Without it, a matching browser already under `PLAYWRIGHT_BROWSERS_PATH` works (Microsoft.Playwright 1.56.0 used the build-1194 Chromium installed for Playwright 1.56, measured 2026-10-15).
|
|
25
26
|
|
|
@@ -22,7 +22,7 @@ description: Writes the final execution report, traceability matrix and troubles
|
|
|
22
22
|
## Output
|
|
23
23
|
The report follows [templates/project-context/report.md](../orion/templates/project-context/report.md), saved as `project-context/runs/<run id>.report.md`. In order:
|
|
24
24
|
1. **Title and verdict.** `# <story title> · test report`, then one bold verdict (✅ Ready to accept · ⚠️ Ready, with notes · ❌ Not ready) and one sentence: what was built and how it ran.
|
|
25
|
-
2. **Facts table:** story, app (URL and environment), tests (count, kind, tool and language, folder), runs (
|
|
25
|
+
2. **Facts table:** story, app (URL and environment), tests (count, kind, tool and language, folder), runs (the counted run, any stability-check runs, and the fail check), date.
|
|
26
26
|
3. **Coverage:** one row per requirement in plain words, the test that covers it, and its result as ✅ n/n · ❌ failed · ⚠️ flaky · ⏭ not run. Cases the user accepted that the story didn't name are marked *(added)*. A requirement with no test says why in the Test column.
|
|
27
27
|
4. **Needs your attention:** at most 5 lines, most important first, each ending with what the user can do. Left out when there is nothing.
|
|
28
28
|
5. **What was added:** tests, page objects, test data and test-case files, one line per kind.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: execution
|
|
3
|
-
description: Runs automated tests with the project's own runner and configuration, scoped to the new and impacted tests (new tests
|
|
3
|
+
description: Runs automated tests with the project's own runner and configuration, scoped to the new and impacted tests (new tests once, retries off; repeated only for a stability check the user asks for), and captures the command, exit code, counts, duration, logs and report paths as evidence. Use when tests need to be run locally or in a working copy.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# execution
|
|
@@ -23,11 +23,11 @@ description: Runs automated tests with the project's own runner and configuratio
|
|
|
23
23
|
**When Playwright's browser can't be downloaded** (a proxy or policy blocks it): don't work around the block; run on the installed Chrome (else Edge) instead and say so in the report: Playwright TS/JS starters `PW_CHANNEL=chrome` (or `msedge`) in the command's environment; Python `--browser-channel chrome`; .NET `-- Playwright.LaunchOptions.Channel=chrome`. A project without that option keeps its own config: report the blocker ([blockers](../orion/references/blockers.md)) with the one fix (allow the download, or add the channel option).
|
|
24
24
|
3. **Command.** Build it from the project's own scripts (package.json scripts, Maven/Gradle tasks, runner config). Don't invent flags the project doesn't use, except the repeat and retry flags in step 5. **The counted runs are the user's own command** (the report's "Run it yourself" line): the project's script with the scope after it (`npm test -- tests/settings.spec.ts`, `mvn test -Dtest=…`), not the runner called around it, and with no setting given only on the command line (output-only flags, such as the reporter and its output file, are fine): a value the run needs (`PW_CHANNEL`, a timeout, a base URL) goes into the project's `.env` (names in `.env.example`), so a manual run, UI mode or the editor's test explorer sees the same. A UI suite also runs once the way an editor or UI mode starts it, only the UI tests and no separate setup step (Playwright `--project=<the tests' project> --no-deps`; pytest `tests/ui`; NUnit `--filter FullyQualifiedName~Ui`; TestNG or JUnit `-Dtest=<class>`); a failure there that the full run doesn't have is a blocking finding (signing in must not depend on a setup step having run, nor trust an old saved session).
|
|
25
25
|
4. **Environment.** Prod → stop unless the brief cites H5. Pass environment variables by name only.
|
|
26
|
-
4a. **Run mode** (existing tests only, `orion/references/modes.md`): the scope is the user's selection, run once, no fail check
|
|
26
|
+
4a. **Run mode** (existing tests only, `orion/references/modes.md`): the scope is the user's selection, run once, no fail check; flaky and failed counts as the runner reports them. **Stability check** (the user asks whether tests are stable or flaky, or to run them N times): run mode with the repeat column of step 5, N from the user (default 3), retries off; all N must agree, mixed results → FLAKY → recovery loop (the failure-analyst checks the live page for that step, a heal is proposed, and that fix is applied only on the user's yes, H14 as in fix mode), then the same N runs again.
|
|
27
27
|
4a2. **Timeouts from the site, any stack.** Before the first run of a new or extended UI or API project: `node .claude/skills/orion/scripts/timing_profile.mjs --project <test project> --maps project-context/ui-maps/<story>.md` writes `timeouts.json` at the test project's root from the explored pages' Timing table; every starter's flags read it in their own terms (Playwright's navigation, action and expect timeouts; Selenium's and Appium's explicit wait; the API clients' request timeout), and an environment variable still wins. An existing suite that has its own timeout settings gets the measured values proposed in the report instead, never edited without the user's yes. After the counted runs, the same with `--results project-context/results/<run id>-<n>.json …` raises the test timeout when a test used more than half of it (never lowers). The report's details list each timeout with its `why`. No Timing table: the defaults stay, said so.
|
|
28
|
-
4b. **Order, so failures cost minutes, not the whole run.** First run only the new tests once, stopping early (`--max-failures=5` for Playwright, the runner's equivalent elsewhere) and with as many workers as the suite's config allows. Failures go to the failure-analyst and are fixed or reported **before** any repeat or full run; never run the full existing suite, or the
|
|
29
|
-
5. **New tests:
|
|
30
|
-
| Runner | Scope |
|
|
28
|
+
4b. **Order, so failures cost minutes, not the whole run.** First run only the new tests once, stopping early (`--max-failures=5` for Playwright, the runner's equivalent elsewhere) and with as many workers as the suite's config allows. Failures go to the failure-analyst and are fixed or reported **before** any repeat or full run; never run the full existing suite, or the counted run, while a known failure is open. Then the counted run (step 5), then the impacted tests (step 6). The full existing suite runs only when the brief asks for it (a regression run, H6), once. Every run's wall time (from the runner's report) goes in the RESULT.
|
|
29
|
+
5. **New tests: 1 counted run, retries off.** The first run of step 4b is the counted run when every new test passed on its first attempt (retries off, through the project's command; record its results, step 8a): no second run. After a fix, the new tests run once more and that run counts. Keep its report. **Repeats only for a stability check** (step 4a) or when the brief names a run count: then N runs (default 3) with the repeat column below; all N must agree, mixed results → `failed`, class FLAKY, with the counts per run, one report per run.
|
|
30
|
+
| Runner | Scope | N runs, retries off (stability check; N = 3 shown) |
|
|
31
31
|
|---|---|---|
|
|
32
32
|
| Playwright Test | `<files>` or `--grep "<title or tag>"` | `--repeat-each=3 --retries=0` |
|
|
33
33
|
| TestNG, JUnit 5 (Maven) | `-Dtest=<Class>` or `<Class>#<method>` (fails when nothing matches; `-Dgroups` with no match runs 0 tests and exits 0) | the command 3 times with `-Dsurefire.rerunFailingTestsCount=0`; copy `target/surefire-reports/` after each run |
|
|
@@ -40,7 +40,7 @@ description: Runs automated tests with the project's own runner and configuratio
|
|
|
40
40
|
6. **Impacted tests: 1 run.** Run the existing tests the reviewer listed as impacted (they import a changed shared file). Failures here go to the failure-analyst like any other.
|
|
41
41
|
6q. **Quiet output (where Node exists).** Run every test, build and install command through the quiet runner: `node .claude/skills/orion/scripts/quiet.mjs <the command exactly as you would type it>`. Same command, same exit code, same approval; it prints the failures with their context, warnings, the runner's counts and the last lines, and saves the full output to `project-context/logs/` (grep that file when you need more, never re-run for output). During an open run a raw runner command is blocked in Claude Code and names this form. Measured: a passing Playwright run 2.3 KB → 0.7 KB of output; a failing one keeps every failure line (2026-11-18-cost-breakdown.md).
|
|
42
42
|
7. **Capture.** Exit code, pass/fail/skip **and flaky** counts as the runner reports them (a test that passed only on retry is flaky, not passed), duration, the last 30 lines of output.
|
|
43
|
-
7a. **Inventory check.** Compare the tests the runner actually executed with the planned scope: new tests ×
|
|
43
|
+
7a. **Inventory check.** Compare the tests the runner actually executed with the planned scope: new tests × counted runs (1, or N for a stability check) + impacted tests. 0 executed, fewer than planned, or a new test reported as skipped is `failed`, never `passed`, even when the exit code is 0: a filter, tag or group that matches nothing, a file outside the runner's test pattern, or a class missing from the suite (AUTOMATION_DEFECT). Never add a pass-with-no-tests flag (Playwright `--pass-with-no-tests`). Run mode: 0 executed → `needs_user` (the selection matches no test). Skipped impacted tests: list each with its skip reason; a skip the base branch doesn't have is a finding.
|
|
44
44
|
8. **Reports.** Record report, trace and screenshot paths by name (e.g. `test-summary/index.html` and `playwright-report/index.html`, `target/surefire-reports/`, `reports/run-1.xml`, `TestResults/*.trx`), taken from the runner config or the command. If the runner writes no report, write `none` and cite the config line. A summary line is not a report path. **In an existing suite, run reports never go into a new folder in it:** per-run files (JSON, JUnit, the HTML report) are written to the workspace's `project-context/results/` (e.g. `--reporter=list,json` with the JSON output file there), or to an output folder the suite's own config already names and ignores.
|
|
45
45
|
8a. **Per-test results (required: the done check counts these files, not the chat).** After each counted run, where a shell and Node exist, from the workspace root (not the worktree; the report path may point into it; the script writes only inside the folder it runs in): `node .claude/skills/orion/scripts/results_parse.mjs <report path> --run <run id>-<n> --out project-context/results/<run id>-<n>.json` (JUnit XML, TRX or Playwright JSON). Get the report from the counted run itself, through the suite's own command, never a second run or a direct runner call. **Playwright starters, and suites with their run summary reporter,** write `test-summary/results.json` on every run, so a counted run is the suite's command as is (`node .claude/skills/orion/scripts/quiet.mjs "cd <project> && npm test -- <spec> --retries=0"`), then `results_parse.mjs <project>/test-summary/results.json --run <run id>-<n> --out project-context/results/<run id>-<n>.json` before the next run overwrites it (measured on the demo suite 2026-11-19: the same 18 results as the JSON route). Other Playwright suites: `node .claude/skills/orion/scripts/quiet.mjs "npm test --silent -- <spec> --retries=0 --reporter=json > project-context/results/<run id>-<n>.pw.json"` (the quotes keep the redirect inside the counted command; for a project in `sut/<app>/`, from the workspace root: `quiet.mjs "cd sut/<app> && npm test --silent -- <spec> --retries=0 --reporter=json > ../../project-context/results/<run id>-<n>.pw.json"`; the runner creates the results folder. Measured on the demo site, 2026-11-19: 3 runs, 18 of 18 each, parsed, done check passed) (`--silent` keeps npm's banner out of the JSON; no environment variable); pytest `--junitxml=<file>`; Maven and Gradle write JUnit XML themselves; `dotnet test --logger trx`. Put its summary line in the RESULT. Exit 1 (no results found) is reported as `results: none parsed` with the report path; it never replaces the runner's own counts.
|
|
46
46
|
9. If anything failed, return `failed` with the run record. Classification is the failure-analyst's job.
|
|
@@ -51,8 +51,8 @@ description: Runs automated tests with the project's own runner and configuratio
|
|
|
51
51
|
- where: <worktree path | work branch + CI run URL> · run_where:
|
|
52
52
|
- device / app build (mobile, desktop): <device, emulator, simulator or session> · <app build and version>
|
|
53
53
|
- command: · exit code: · duration:
|
|
54
|
-
- executed / planned: <n> / <n> (new tests ×
|
|
55
|
-
- new tests,
|
|
54
|
+
- executed / planned: <n> / <n> (new tests × runs + impacted; run mode: executed / `selection`)
|
|
55
|
+
- new tests, counted run(s): passed / failed / skipped / flaky per run
|
|
56
56
|
- impacted tests: passed / failed / skipped / flaky
|
|
57
57
|
- failing tests: <names>
|
|
58
58
|
- reports: <paths — required, or `none` + config file:line>
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# C# API tests (HttpClient, NUnit). Runs on PRs, pushes to the default branch, and on demand: the executor triggers it with
|
|
3
3
|
# actions_run_trigger (run_workflow) on the work branch and reads the result with get_job_logs.
|
|
4
4
|
# Actions are pinned to commit SHAs (tag in the comment, resolved 2026-10-15); update them with Dependabot.
|
|
5
|
-
# "repeat: 3" runs the selection three times with retries off (
|
|
5
|
+
# "repeat: 3" runs the selection three times with retries off (a stability check); any failing run fails the job.
|
|
6
6
|
name: api-tests
|
|
7
7
|
on:
|
|
8
8
|
pull_request:
|
|
@@ -22,7 +22,7 @@ on:
|
|
|
22
22
|
required: false
|
|
23
23
|
default: ""
|
|
24
24
|
repeat:
|
|
25
|
-
description: "Runs of the selection (3 for
|
|
25
|
+
description: "Runs of the selection (3 for a stability check)"
|
|
26
26
|
type: choice
|
|
27
27
|
options: ["1", "3"]
|
|
28
28
|
default: "1"
|
|
@@ -19,6 +19,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
19
19
|
- Maven: `mvn -q -DskipTests test-compile`
|
|
20
20
|
- Gradle: `./gradlew compileTestJava`
|
|
21
21
|
- Use the wrapper (`./mvnw`, `./gradlew`) if present.
|
|
22
|
+
- Format with the project's Spotless (`mvn spotless:apply`, `./gradlew spotlessApply`) when it has it; none → offered at Gate 4 (Spotless with google-java-format), never added silently.
|
|
22
23
|
|
|
23
24
|
## Failure signals
|
|
24
25
|
`cannot find symbol` / `package … does not exist` → AUTOMATION_DEFECT (or missing dependency → needs_user H10). `UnsupportedClassVersionError` → NEEDS_ENVIRONMENT (JDK version).
|
|
@@ -22,6 +22,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
22
22
|
## Check
|
|
23
23
|
- Playwright: `npx playwright test --list` loads every spec (syntax and import errors surface) without running.
|
|
24
24
|
- Other runners: `node --check <file>` per new file, and the project's `lint` script if present; don't add lint rules.
|
|
25
|
+
- Format: `npx prettier --write <changed files>` when the project has Prettier (the Playwright starters do); never the whole repo.
|
|
25
26
|
|
|
26
27
|
## Failure signals
|
|
27
28
|
| Signal | Likely class |
|
|
@@ -22,7 +22,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
22
22
|
- Gradle: `./gradlew test --tests LoginTest` (the build must call `useJUnitPlatform()`). Reports: `build/reports/tests/`.
|
|
23
23
|
|
|
24
24
|
## Repeat and flaky (platform rules)
|
|
25
|
-
- New tests: run the scoped command
|
|
25
|
+
- New tests: run the scoped command once with `-Dsurefire.rerunFailingTestsCount=0`; a stability check the user asks for runs it N times (default 3), all N must agree. Don't leave `@RepeatedTest` in the code for this.
|
|
26
26
|
- Report tests that passed only on a rerun as flaky, never as passed.
|
|
27
27
|
|
|
28
28
|
## Failure signals
|
|
@@ -26,7 +26,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
26
26
|
- New project: [templates/project](templates/README.md) (the suite architecture: `src/config/env.js` from the environment then `.env`, a client per resource in `src/services/`, data and builders in `resources/testData/testData.js`, cases in `resources/desc/`, `tests/load/products.js` with both profiles).
|
|
27
27
|
|
|
28
28
|
## Run
|
|
29
|
-
- Verification (covered by the build request, like any new test): `k6 run --quiet -e BASE_URL=<test env> -e API_TOKEN=$API_TOKEN load/<script>.js` with the smoke profile,
|
|
29
|
+
- Verification (covered by the build request, like any new test): `k6 run --quiet -e BASE_URL=<test env> -e API_TOKEN=$API_TOKEN load/<script>.js` with the smoke profile, once, exit 0 (a stability check on request: N times, each exit 0) [S4, M1].
|
|
30
30
|
- Fail check: tighten one threshold (`-e P95_MS=1` or a copy with `p(95)<1`) and show exit 99 on that threshold (M2), then restore it.
|
|
31
31
|
- The load run (H6 only): `-e PROFILE=load`, plus `--summary-export reports/k6-summary.json` [S6, M6]. Report p95, p99, error rate and checks from the summary, each against its threshold.
|
|
32
32
|
- Exit codes: 0 all thresholds passed; **99 a threshold failed** (M2, M3, M5); **107 a script or setting error** (M9).
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Products API under load. Smoke profile by default (1 VU, 1 iteration): that is what verification runs
|
|
2
|
+
* Products API under load. Smoke profile by default (1 VU, 1 iteration): that is what verification runs.
|
|
3
3
|
* PROFILE=load runs the profile you approved (H6). Every check is bound to a threshold, so a failed check fails the run.
|
|
4
4
|
*/
|
|
5
5
|
import { check, group, sleep } from 'k6';
|
|
@@ -22,7 +22,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
22
22
|
## Run
|
|
23
23
|
- `mvn test -Dtest=ApiTest` (the runner class) · scope by tag: `-Dkarate.options="--tags @smoke"` · one feature: `-Dkarate.options="classpath:api/users.feature"`.
|
|
24
24
|
- The template's runner fails when no scenario ran (a tag that matches nothing would otherwise exit 0) and when any scenario failed.
|
|
25
|
-
- New tests: the command
|
|
25
|
+
- New tests: the command once with `-Dsurefire.rerunFailingTestsCount=0`; a stability check on request runs it N times, all must pass.
|
|
26
26
|
- Reports: `target/karate-reports/karate-summary.html`, `target/surefire-reports/`.
|
|
27
27
|
|
|
28
28
|
## Failure signals
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# Karate (Java, JUnit 5, Maven). Runs on PRs, pushes to the default branch, and on demand: the executor triggers it with
|
|
3
3
|
# actions_run_trigger (run_workflow) on the work branch and reads the result with get_job_logs.
|
|
4
4
|
# Actions are pinned to commit SHAs (tag in the comment, resolved 2026-10-15); update them with Dependabot.
|
|
5
|
-
# "repeat: 3" runs the selection three times with retries off (
|
|
5
|
+
# "repeat: 3" runs the selection three times with retries off (a stability check); any failing run fails the job.
|
|
6
6
|
name: api-tests
|
|
7
7
|
on:
|
|
8
8
|
pull_request:
|
|
@@ -22,7 +22,7 @@ on:
|
|
|
22
22
|
required: false
|
|
23
23
|
default: ""
|
|
24
24
|
repeat:
|
|
25
|
-
description: "Runs of the selection (3 for
|
|
25
|
+
description: "Runs of the selection (3 for a stability check)"
|
|
26
26
|
type: choice
|
|
27
27
|
options: ["1", "3"]
|
|
28
28
|
default: "1"
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# Postman collection (Newman). Runs on PRs, pushes to the default branch, and on demand: the executor triggers it with
|
|
3
3
|
# actions_run_trigger (run_workflow) on the work branch and reads the result with get_job_logs.
|
|
4
4
|
# Actions are pinned to commit SHAs (tag in the comment, resolved 2026-10-15); update them with Dependabot.
|
|
5
|
-
# "repeat: 3" runs the selection three times with retries off (
|
|
5
|
+
# "repeat: 3" runs the selection three times with retries off (a stability check); any failing run fails the job.
|
|
6
6
|
name: api-tests
|
|
7
7
|
on:
|
|
8
8
|
pull_request:
|
|
@@ -22,7 +22,7 @@ on:
|
|
|
22
22
|
required: false
|
|
23
23
|
default: ""
|
|
24
24
|
repeat:
|
|
25
|
-
description: "Runs of the selection (3 for
|
|
25
|
+
description: "Runs of the selection (3 for a stability check)"
|
|
26
26
|
type: choice
|
|
27
27
|
options: ["1", "3"]
|
|
28
28
|
default: "1"
|
|
@@ -28,7 +28,7 @@ function settings() {
|
|
|
28
28
|
return {
|
|
29
29
|
baseUrl,
|
|
30
30
|
token: process.env.API_TOKEN || '',
|
|
31
|
-
runs: Number(process.env.TEST_REPEAT || '1'), //
|
|
31
|
+
runs: Number(process.env.TEST_REPEAT || '1'), // N for a stability check: every iteration must pass
|
|
32
32
|
folder: process.env.TEST_FILTER || undefined, // a folder or request name in the collection
|
|
33
33
|
runWriteTests: process.env.RUN_WRITE_TESTS === '1', // `write` cases create data
|
|
34
34
|
};
|
|
@@ -24,7 +24,7 @@ Adapter rules: holds only what differs from the capability skills; the project's
|
|
|
24
24
|
- Settings such as `BROWSER` or `HEADED` come from environment variables or a `.runsettings` file without secrets.
|
|
25
25
|
|
|
26
26
|
## Repeat and flaky (platform rules)
|
|
27
|
-
- New tests: run the scoped command
|
|
27
|
+
- New tests: run the scoped command once; a stability check on request runs it N times (default 3), all N must agree. Don't leave `[Repeat]` or `[Retry]` in the code.
|
|
28
28
|
- Report tests that passed only on a rerun as flaky, never as passed.
|
|
29
29
|
|
|
30
30
|
## Failure signals
|
|
@@ -52,7 +52,7 @@ Symbols: ✓ passed · ▶ in progress · ⏸ waiting for the user · ✗ failed
|
|
|
52
52
|
| 3 | Stack, patterns, reuse candidates with file evidence (no repo: `greenfield` + the chosen starter template) | codebase-analyst |
|
|
53
53
|
| 4 | Strategy recorded; user approval if stack/architecture changes | automation-strategist + user |
|
|
54
54
|
| 5 | The review ran (single-agent: the `code-review` and `automation-review` skills applied as their own step over the diff, findings listed; not run → `not run`, never ✓); zero blocking review findings, or one revision done and the rest listed as known issues of a delivered draft; fail check recorded for every new test (or `not run` with reason) | reviewer |
|
|
55
|
-
| 6 | Real runner used from a normal shell (no sandbox-only browser path), output captured; new tests passed
|
|
55
|
+
| 6 | Real runner used from a normal shell (no sandbox-only browser path), output captured; new tests passed their counted run with retries off (all N runs when a stability check was asked); the fail check failed on its assertion; impacted existing tests run | executor (+ failure-analyst) |
|
|
56
56
|
| 7 | The evidence check ran over the result (single-agent: the `evidence-validation` skill as its own step); every summary claim supported; a `fail` verdict keeps Gate 7 open until its re-check returns pass | evidence-validator |
|
|
57
57
|
| 8 | `done_check.mjs` exits 0, or after 3 rounds its failing rows are the result's ⚠️ lines (step 4d); every AC is a passing test or named in the result with the reason it isn't; user accepts | you + user |
|
|
58
58
|
|
|
@@ -9,7 +9,7 @@ Agents, in order; Gate numbers as in the run file. **First reply: only the basel
|
|
|
9
9
|
- `node .claude/skills/orion/scripts/reuse_check.mjs <folder> --json`: repeated or unused code (M1, M4, U9);
|
|
10
10
|
- `node .claude/skills/orion/scripts/graph.mjs build --suite <folder>`: the links between tests, page objects and any cases.
|
|
11
11
|
Its RESULT: the technology and architecture profiles, the script findings as rows, and the suite's run command and base URL with the config file:line they come from. On a host where it has no shell, it reads the files and says `scripts not run: <reason>`; the findings it judges are tagged `judged`.
|
|
12
|
-
2. **Baseline run (Gate 6, H6).** Ask once, naming the exact command and the base URL the suite will use (from its config, not a guess). Never against production (H5 and the production refusal apply); tests tagged as changing data run only if the user says so. executor runs it once (no
|
|
12
|
+
2. **Baseline run (Gate 6, H6).** Ask once, naming the exact command and the base URL the suite will use (from its config, not a guess). Never against production (H5 and the production refusal apply); tests tagged as changing data run only if the user says so. executor runs it once (no repeats, no fail check) and writes the results file with `results_parse.mjs`. Failures go to failure-analyst for a class each. No run (declined, no environment): the assessment says `baseline: not run (<reason>)` and fix mode can't start until one exists. **The baseline changes nothing in the suite either:** it runs only with dependencies that are already there (or restored from the suite's own lockfile without changing it: `npm ci`, `mvn dependency:resolve`, `dotnet restore`, each as part of the H6 question). An install that would create or change a tracked file (`npm install` without a lockfile writes `package-lock.json`) isn't done: the baseline is `not run (dependencies not installed)` and the assessment gives the user the one command to run.
|
|
13
13
|
3. **Review (Gate 5, review part).** reviewer, brief `mode: assess`: applies every U, P and M row of the pattern rules to the **whole suite** (not a diff), confirms or rejects each script finding with the line it read, adds the judged ones (U3 shared data, U4 branching, U8/U12 assertion strength, P3, P4, P7, P9–P13, M1–M6) with file:line, gives each finding's fix the files it edits (the "Changes" column: a P1 fix names the page object and the test the assertion moves into; never an app file), and writes the architecture section against `patterns.md`. A redesign beyond a finding's own fix is not proposed.
|
|
14
14
|
4. **Evidence (Gate 7).** evidence-validator checks every finding's file:line and quote.
|
|
15
15
|
5. **Save and stop.** The orchestrator writes `project-context/assessments/A-<YYYYMMDD>-<HHMM>/assessment.md` from `templates/project-context/assessment.md` (verdict, facts, top issues in plain words, what's good, how to fix; the full findings table numbered F-1…, most severe first, with the baseline, architecture and what wasn't assessed, inside the folded engineer block), checks it with `node .claude/skills/orion/scripts/report_check.mjs <assessment.md>` until it passes (no shell: by hand, said so), and shows at most 8 lines in chat: the bold verdict with one sentence; "Baseline: " the result; "Findings: 🔴 n critical · 🟠 n blocking · 🟡 n major · ⚪ n minor"; the top 3 issues, one line each in plain words with `file:line`; "Report: `<path>`"; "To fix: say which ones, like *fix F-2 and F-5* or *do the quick wins* (you choose the items; nothing else changes)". With a shell, `graph.mjs build` again so findings show on their files.
|
|
@@ -45,7 +45,7 @@ State lives in `project-context/batches/B-<date>-<time>-<slug>/batch.json`. `nod
|
|
|
45
45
|
4. **Approval (the one checkpoint for test cases):** the test-case tables in pages of at most 10 stories. The user approves a page, single stories, or edits. A design batch ends here.
|
|
46
46
|
5. **Foundation:** page objects, fixtures and helpers that two or more stories need, built once on the batch branch, then reviewed and committed locally (H3). Its commit is the batch's `foundation`.
|
|
47
47
|
6. **Build:** K stories at a time, each in its own work copy from the foundation commit ([work-branch.md](work-branch.md)). A story never edits a foundation file. A change it needs there goes back to the foundation step, and the reviewer blocks it otherwise.
|
|
48
|
-
7. **Verify:** reviewer, then executor (
|
|
48
|
+
7. **Verify:** reviewer, then executor (1 counted run, retries off) per story, at most 2 runs at a time on a shared test environment.
|
|
49
49
|
8. **Integration:** one story at a time is merged into the batch branch, then `graph.mjs check` runs, then one regression run (H6), then the story is accepted (one H13 for all, listing each story).
|
|
50
50
|
|
|
51
51
|
**Status:** one line at each wave boundary, from `batch_state.mjs <batch.json> summary` ("Wave 6/8 build: SHOP-3, SHOP-7 · 5 of 12 done · USD 31 of 80"), and no narration in between.
|
|
@@ -29,7 +29,7 @@ API support by language and style (REST, GraphQL, schema, what is on request): `
|
|
|
29
29
|
- **Locators:** from the live app; converted per language and **proven** (one match, same element) with `ui-observation/references/locator-conversion.md`; the reviewer blocks unproven ones where a browser exists.
|
|
30
30
|
- **Reuse first** (AGENTS rule 7): every writer searches for what exists before adding (implementer `searched:` rows, reviewer rule U9, heals change the existing locator, the reporter checks for duplicate cases and defects).
|
|
31
31
|
- **Patterns:** `code-review/references/pattern-rules.md` (U rows always block, P rows for the project's patterns, M rows advisory); the implementer self-checks against the same table.
|
|
32
|
-
- **Assertions:** never weakened (assertion guard covers TS, JS, Java, Python, C#, REST); every new test has a fail check; new tests pass
|
|
32
|
+
- **Assertions:** never weakened (assertion guard covers TS, JS, Java, Python, C#, REST); every new test has a fail check; new tests pass with retries off; a stability check ("are these stable?") runs them N times on request, and a flaky one is checked against the live page and fixed on your yes.
|
|
33
33
|
- **Secrets:** names only; templates keep tokens and passwords out of output (pytest `--tb=short`, Karate header masking); screenshots stay in `.ui-map/`, never committed.
|
|
34
34
|
|
|
35
35
|
## Optional quality checks (only when the user picks them on the setup card)
|
|
@@ -60,14 +60,14 @@ Two checkpoints, nothing more: the setup card (all questions at once, defaults i
|
|
|
60
60
|
- Plain sentences ([status-lines.md](status-lines.md)): what you are doing, the folder path, the test list, the command results, any real blocker. No gate board, decision IDs, "recorded", or specialist names.
|
|
61
61
|
- **The first reply to a build or design request is the setup card** (or the greeting card for a greeting): its eight questions, each with a default, never a list of open questions without defaults, and never a page observation or code before the user said go.
|
|
62
62
|
- **The result is one short message: exactly the 5 numbered lines below, each its own paragraph (a blank line between them, or a chat window runs them together), at most 120 words before "Accept?" (count them; code paths count as one word), no line over 30 words**, the report's top in chat form, in this order. No sentence before line 1 and none between the lines: no intro ("I wrote 8 tests…"), no repeat of the story not being read (line 4 says it once if it matters), no password note (said once, when the account was pasted, never again), no "To run the tests yourself". Never a per-test table, a file list, the run command, or notes on the platform's own checks: what the report checker or a type checker said, a starter check you removed or changed, a reload to do; those go in the report, and a checker that flags the app's own name is noted there as a checker problem):
|
|
63
|
-
1. **The verdict, bold, then what was built and how it ran**, the same verdict as the report (✅ Ready to accept · ⚠️ Ready, with notes · ❌ Not ready): "**✅ Ready to accept**: 10 tests in `sut/<app>/tests`, passed
|
|
63
|
+
1. **The verdict, bold, then what was built and how it ran**, the same verdict as the report (✅ Ready to accept · ⚠️ Ready, with notes · ❌ Not ready): "**✅ Ready to accept**: 10 tests in `sut/<app>/tests`, all passed with retries off (10 of 10); each failed when its check was broken."
|
|
64
64
|
2. "Login: " automated and how, or why not.
|
|
65
65
|
3. "Coverage: " on one line, never a table (the report keeps its coverage table; the chat gets this line): each requirement in a few words with its test ids, or why one has none: "Coverage: log in → TS-1, TS-2 · log out → TS-3 · checkout → not covered (needs a payment account)."
|
|
66
66
|
4. At most two lines, each starting "⚠️ ", at most 25 words, on what changes the user's next step and what to do about it: a defect found, a test not run, a check skipped or only reported, a risk to their account or data. The finding and the action, nothing about how you found it: "⚠️ TS-4 expects an alert the site doesn't show for a malformed email: say \"fix TS-4\" and I'll correct it (asks first)." None → no line.
|
|
67
67
|
5. "Report: `<report path inside the workspace>`".
|
|
68
68
|
A full example, 89 words before "Accept?":
|
|
69
69
|
```
|
|
70
|
-
**✅ Ready to accept**: 9 tests in `sut/<app>/tests/ui`, passed
|
|
70
|
+
**✅ Ready to accept**: 9 tests in `sut/<app>/tests/ui`, all passed with retries off (9 of 9); each failed when its check was broken.
|
|
71
71
|
|
|
72
72
|
Login: automated, signed in once through the form and the session reused.
|
|
73
73
|
|
|
@@ -90,5 +90,5 @@ Two checkpoints, nothing more: the setup card (all questions at once, defaults i
|
|
|
90
90
|
| 1 Start | — | the setup card; wait for go |
|
|
91
91
|
| 2 Understand | 1, 2, 3 | "The site asks for a browser login first; behind it, the women's handbags listing has 48 products, the first in stock is …" |
|
|
92
92
|
| 3 Design | 4 | the test-case table (ID · What it checks · Type · Priority · Expected) and "Shall I write these?"; wait (design mode stops here for acceptance) |
|
|
93
|
-
| 4 Build | 5, 6 | "5 tests in sut/coach/tests. `npm test` passed
|
|
93
|
+
| 4 Build | 5, 6 | "5 tests in sut/coach/tests. `npm test` passed; a wrong quantity failed on that assertion." |
|
|
94
94
|
| 5 Deliver | 7, 8 | the folder, the tests, the results, the one-line login and coverage statements, "**Accept?** Reply **yes**, or tell me what to change." and a "What next" line |
|
|
@@ -5,7 +5,7 @@ A run does only what the user asked for and stops at that mode's stop point. It
|
|
|
5
5
|
| Mode | Start (command or plain words) | Agents, in order | Gates | Stops when | Approvals that can come up | Writes |
|
|
6
6
|
|---|---|---|---|---|---|---|
|
|
7
7
|
| **full** (default) | `/orion <story>` · "automate this story" | requirement-analyst → environment-discovery ∥ codebase-analyst → automation-strategist → implementer → reviewer → executor (+ failure-analyst) → evidence-validator → you (report) → test-reporter only if you ask to share | 1–8 | you accept the report (H13), or decline it | as they arise, except that exploring the test URL and running the new tests on this machine are part of the request; running the rest of the suite or CI is H6 | the existing suite, extended in place on a local work branch (`work-branch.md`); PR only with H4 |
|
|
8
|
-
| **build** | `/orion build <story>` · "write the tests / give me the script", with a test URL; the workspace has no suite for this app (or it is the agent install) | requirement-analyst → environment-discovery (opens the URL first) → automation-strategist (test cases from the sentence and the live site; default stack Playwright + JavaScript unless named) → implementer (starter template + UI map, in `sut/<app>/`) → reviewer (one round) → executor (
|
|
8
|
+
| **build** | `/orion build <story>` · "write the tests / give me the script", with a test URL; the workspace has no suite for this app (or it is the agent install) | requirement-analyst → environment-discovery (opens the URL first) → automation-strategist (test cases from the sentence and the live site; default stack Playwright + JavaScript unless named) → implementer (starter template + UI map, in `sut/<app>/`) → reviewer (one round) → executor (1 counted run on this machine) → you (deliver) | 1, 2, 4, 5, 6, 7, 8; 3 `greenfield: <template>` | the suite in `sut/<app>/` passes its counted run (or is delivered with its failures and known issues), and you accept it or ask for changes | the setup card (go / change) before anything starts, and the test-case table (go / change) before code; the confirmed card covers exploring the URL, installing the runner and browser in `sut/<app>/`, and running the new tests here. Asked: H5 production, H3/H4 git, H8 an expected value, H10 installs outside `sut/<app>/` | `sut/<app>/` only (`work-branch.md`); a zip, PR, chat code or test-case files only when asked (`delivery-formats.md`); never a commit or push without H3 |
|
|
9
9
|
| **analyze** | `/orion analyze <repo or folder>` · "analyse / what's the stack of …" | environment-discovery ∥ codebase-analyst → evidence-validator | 2, 3, 7; others `n/a — analyze` | the analysis report is shown | none (read-only); H11 if it would need a database | none (facts may be written to `project-context/` on hosts with files) |
|
|
10
10
|
| **design** | `/orion design <story>` · "only the test cases" | requirement-analyst → environment-discovery ∥ codebase-analyst → automation-strategist → evidence-validator | 1–4, 7, 8; 5, 6 `n/a — design` | you accept the test design (H13); then, unless a format was named, one line offers the test cases as a file (`delivery-formats.md`) | H1, H2; exploring the test URL the user gave is part of the request (no URL → the map is `not observed` and the design says its cases are `not checked against the app`) | the test-case files you ask for (Excel, CSV, PDF, Word, HTML, Markdown, Gherkin, JSON, a TestRail / Xray / Zephyr Scale / Azure Test Plans import file) under `project-context/test-designs/<story>/`, all by `cases_export.py`; writing into the tool itself only on request (H9, test-reporter) |
|
|
11
11
|
| **review** | `/orion review <PR, branch, diff or files>` · "review these tests" | reviewer | 5 (review part only) | the findings are shown | none | none; fixes only if you then start a full run |
|
|
@@ -17,7 +17,7 @@ People say what they want in their own words, with typos, in another language, h
|
|
|
17
17
|
## What people say → what happens
|
|
18
18
|
| They might say | It means | Shortcut (optional) |
|
|
19
19
|
|---|---|---|
|
|
20
|
-
| "automate this story", "write tests for PR-1 on https://…", "test login and cart on this site" | full or build: setup card, test cases, tests,
|
|
20
|
+
| "automate this story", "write tests for PR-1 on https://…", "test login and cart on this site" | full or build: setup card, test cases, tests, 1 counted run | `/orion <story>` · `/orion build …` |
|
|
21
21
|
| "just the test cases", "no code yet", "design the tests", "what should we test for this" | design: stops at the accepted cases | `/orion design <story>` |
|
|
22
22
|
| "what's in this repo", "what framework is this", "analyse our tests" | analyze: stack and structure, read-only | `/orion analyze <folder>` |
|
|
23
23
|
| "how good are our tests", "what's wrong with our framework", "audit the suite" | assess: findings and a fix plan | `/orion assess` |
|
|
@@ -25,6 +25,7 @@ People say what they want in their own words, with typos, in another language, h
|
|
|
25
25
|
| "review this PR", "check these tests", "is this test any good" | review: findings only | `/orion review …` |
|
|
26
26
|
| "why did this fail", "checkout is red", "here's the log, what happened" | triage: the cause with evidence | `/orion triage …` |
|
|
27
27
|
| "run the smoke tests", "run everything tagged @cart", "rerun login" | run: asks once, then runs | `/orion run …` |
|
|
28
|
+
| "are these tests stable", "is TS-3 flaky", "run them 5 times" | run as a stability check: N runs (default 3), retries off; a flaky test is checked on the live page and fixed only on your yes, then run N times again | — |
|
|
28
29
|
| "do all the stories in the sprint", "these 6 tickets", "the whole epic" | batch: a plan card first | `/orion batch …` |
|
|
29
30
|
| "just check these locators", "only write the defect for this bug", "export last run's results to TestRail" (one small job) | task: that one job, its own approvals only ([modes.md](modes.md), task mode) | — |
|
|
30
31
|
| "how did last sprint go", "summary of runs", "trend" | report across runs | `/orion report …` |
|
|
@@ -52,6 +53,6 @@ People say what they want in their own words, with typos, in another language, h
|
|
|
52
53
|
Answer in at most five short lines, in plain words, with the numbers below only where they were measured:
|
|
53
54
|
- **Quiet Runner:** test runs show only the failures with their context and the counts; the full log is kept for when it's needed (a passing run 2.3 KB → 0.7 KB; real runs' output roughly halved).
|
|
54
55
|
- **Code Map:** your suite as one line per file, with line numbers, so agents open only what they change (a 13 KB suite → 1.6 KB).
|
|
55
|
-
- **Smart Reading:** each step reads only the part of Orion's rules it needs (the setup rules
|
|
56
|
+
- **Smart Reading:** each step reads only the part of Orion's rules it needs (the setup rules 15 KB → 1.5 KB).
|
|
56
57
|
- **Reuse Ladder:** reuse what you have, then extend it, then combine it, and only then write the smallest new code; copied code fails the finish check.
|
|
57
58
|
- **Done Check and Lean Guard:** "done" is checked by a script, not the agent's word, and wasteful habits are blocked during a run on every tool with hooks.
|
|
@@ -9,11 +9,11 @@ executor RESULT with failures
|
|
|
9
9
|
APPLICATION_DEFECT → show defect draft; ask to file it (H9, listing the draft and the target project); on yes → test-reporter `file-defects` with the D-nnn; test stays failing, never healed
|
|
10
10
|
RETRYABLE → executor reruns the same tests (no code change), per retry-policy.md
|
|
11
11
|
FLAKY on an existing test → one rerun; still inconsistent → report as flaky, don't heal
|
|
12
|
-
FLAKY on a new test (mixed results
|
|
12
|
+
FLAKY on a new test (mixed results across the runs of a stability check) → treat as AUTOMATION_DEFECT: failure-analyst finds the cause (wait, data, order) → heal proposal; a new test is never accepted while flaky
|
|
13
13
|
TEST_DATA_ISSUE / AUTOMATION_DEFECT → heal proposal
|
|
14
14
|
→ reviewer (code-review + assertion guard) → blocking? → back to failure-analyst with findings (counts as an attempt)
|
|
15
15
|
→ append the changed rows to the UI map; implementer applies exactly the proposal, changing the script from those rows
|
|
16
|
-
→ executor reruns failing tests, then the affected file/suite (new tests:
|
|
16
|
+
→ executor reruns failing tests, then the affected file/suite (new tests: 1 counted run, retries off, or N in a stability check; fail check again when the heal touched what an assertion reads); in CI, the heal is pushed first as a follow-up commit under the run's H3 (work-branch.md step 5)
|
|
17
17
|
→ pass → evidence-validator → report
|
|
18
18
|
→ fail → next attempt (1 → 2 → ESCALATE)
|
|
19
19
|
NEEDS_ADAPTER → new-technology path (H12)
|
|
@@ -4,7 +4,7 @@ The user wants results and questions, not a narration of the machinery. Everythi
|
|
|
4
4
|
|
|
5
5
|
## Hosts that show their own activity (Claude Code, Cursor, GitHub Copilot, Codex, Gemini CLI, Windsurf, Grok Build)
|
|
6
6
|
- **No narration, three milestones.** The host already shows each file read, command and tool call. Write only: the one question you need, a result the user can use, a blocker, the deliverable. No "I'll…" lines between tool calls ("I'll pull, free the port and install", "I'll write the suite, then review it"), and no reasoning out loud while working ("Next I'll run the regression three times", "The checker wants a results file", "The output was cut off, so I'll rerun it", "I'll fix both"): the first text the user sees is the setup card, and during a build only the three milestones below. Fixing your own checker findings is silent work; its outcome shows in the result.
|
|
7
|
-
- **Milestone lines** (a long run otherwise shows minutes of tool output and no sentence): one line, at most three times in a build or full run, each a result that just happened plus what comes next, never a plan: after exploring ("Signed in and mapped 4 pages; all 23 locators matched exactly one element. Designing the test cases."), after the code is reviewed ("8 tests written and reviewed in `sut/shop/tests`. Running them
|
|
7
|
+
- **Milestone lines** (a long run otherwise shows minutes of tool output and no sentence): one line, at most three times in a build or full run, each a result that just happened plus what comes next, never a plan: after exploring ("Signed in and mapped 4 pages; all 23 locators matched exactly one element. Designing the test cases."), after the code is reviewed ("8 tests written and reviewed in `sut/shop/tests`. Running them."), and after a slow install ("Playwright and Chromium installed in `sut/shop/`."). No milestone may restate one already sent.
|
|
8
8
|
- **No step names, icons or prefixes** in chat: never `Understand ·`, `Design ·`, `Mode:`, `Confirmed:`, `⛔`, `📖` or the like. Two exceptions: the one-line confirmation of a decision the user just made, led by **Approved:**, **Updated:**, **Understood, …** or **All set:** ([conversation.md](conversation.md), Voice), and the result: its bold verdict (✅ ⚠️ ❌) and "⚠️ " on its attention lines, the same marks as the report ([conversation.md](conversation.md), "What the user sees"). The steps and gates are internal; they live in the run file.
|
|
9
9
|
- Each message is plain sentences: what you found or did, then what you need (if anything). Numbers come from accepted RESULTs and the run file's `Run state` (UI map, test design, executor's `executed / planned`); no number without its source.
|
|
10
10
|
|
|
@@ -26,14 +26,14 @@ Signed in and mapped 3 pages: login, 6 products each with Add to cart, the cart.
|
|
|
26
26
|
[the test-case table: ID · What it checks · Type · Priority · Expected]
|
|
27
27
|
8 test cases, from your request and what the site shows. **Shall I write these?** Reply **go**, or tell me what to change in your own words, like "add a locked-out user" or "drop the fourth one".
|
|
28
28
|
[user: go]
|
|
29
|
-
8 tests written and reviewed in sut/saucedemo/tests. Running them
|
|
30
|
-
**⚠️ Ready, with notes**: 8 tests in `sut/saucedemo/tests`,
|
|
29
|
+
8 tests written and reviewed in sut/saucedemo/tests. Running them.
|
|
30
|
+
**⚠️ Ready, with notes**: 8 tests in `sut/saucedemo/tests`, 7 of 8 pass with retries off; each failed when its check was broken.
|
|
31
31
|
|
|
32
32
|
Login: automated, signed in once per run and the session reused.
|
|
33
33
|
|
|
34
34
|
Coverage: log in → TS-1, TS-2 · add to cart → TS-3 to TS-5 · cart → TS-6 to TS-8.
|
|
35
35
|
|
|
36
|
-
⚠️ TS-6 fails
|
|
36
|
+
⚠️ TS-6 fails: the app shows a different locked-out message than the story says. A defect draft is in the report; reply "file it" to send it to Jira.
|
|
37
37
|
|
|
38
38
|
Report: `project-context/runs/R-20261113-1010-cart.report.md`
|
|
39
39
|
|
|
@@ -34,7 +34,7 @@ Name files in `inputs`; don't paste their content into the brief. On Claude Code
|
|
|
34
34
|
| implementer (clone task, before Gate 3) | the `git clone` command with its exit code and the clone's absolute path; `Changes` lists only that folder |
|
|
35
35
|
| implementer (Gate 5) | per new or changed locator: the UI map row it came from (or `top-up` rows it added, or `unverified` on a host without a browser); the pattern rules self-check list; a fail check row per new test (or `not run` + reason); compile/collect command with exit code |
|
|
36
36
|
| reviewer (Gate 5) | the `Pattern rules checked` line, the assertion inventory per changed test, and every blocking finding with its rule ID or evidence |
|
|
37
|
-
| executor (Gate 6) | command, exit code, `executed / planned` counts, per-run results for new tests (
|
|
37
|
+
| executor (Gate 6) | command, exit code, `executed / planned` counts, per-run results for new tests (1 counted run, or N for a stability check), report paths |
|
|
38
38
|
| failure-analyst | the class with its evidence line; UI failures: the `heal` capture (fresh snapshot, screenshot, `error-context.md` if Playwright JS/TS) and the changed UI map rows; a heal proposal with same-target proof |
|
|
39
39
|
| evidence-validator (Gate 7) | each summary claim marked supported / unsupported / contradicted |
|
|
40
40
|
A UI story never reaches Gate 5 without a UI map or a recorded `not observed` reason, and scripts are never written before it (`ui-observation`, "Explore once, write after").
|
|
@@ -75,7 +75,7 @@ export function next(b) {
|
|
|
75
75
|
if (b.workflow === 'design') return { wave: 'done', start: [], why: `${done(b)} of ${b.stories.length} stories designed and approved` };
|
|
76
76
|
if (at(b, 'approved').length && !b.foundation) return { wave: 'foundation', start: ['foundation'], why: 'shared page objects, fixtures and helpers built once, before any story' };
|
|
77
77
|
if (at(b, 'approved').length) return { wave: 'build', start: at(b, 'approved').slice(0, k).map((s) => s.key), why: `stories built ${k} at a time, each in its own work copy from the foundation` };
|
|
78
|
-
if (at(b, 'built').length) return { wave: 'verify', start: at(b, 'built').slice(0, Math.min(k, 2)).map((s) => s.key), why: 'review and
|
|
78
|
+
if (at(b, 'built').length) return { wave: 'verify', start: at(b, 'built').slice(0, Math.min(k, 2)).map((s) => s.key), why: 'review and the counted run per story, at most 2 runs at a time on a shared environment' };
|
|
79
79
|
if (at(b, 'verified').length) return { wave: 'integration', start: at(b, 'verified').slice(0, 1).map((s) => s.key), why: 'merged one at a time, graph check and one regression run, then accepted' };
|
|
80
80
|
return { wave: 'done', start: [], why: `${done(b)} of ${b.stories.length} stories accepted` };
|
|
81
81
|
}
|