Skip to content

docs(testing): one strategy plus pointers — docs/testing is STRATEGY.md, the catalog and JOURNEYS.md, guarded (#2339) - #2758

Merged
vybe merged 1 commit into
devfrom
feature/2339-testing-docs-strategy
Sep 14, 2026
Merged

vybe merged 1 commit into
devfrom
feature/2339-testing-docs-strategy

Conversation

@webmixgamer

Copy link
Copy Markdown
Contributor

Summary

Rail R5 of the journey-coverage deck (epic #1850). docs/testing/ becomes one strategy document plus pointer targets, and a unit guard keeps it that way.

  • docs/testing/STRATEGY.md (new): the method — promise tests (journeys), invariant tests (catalog + canary), regression tests — the CI lanes as built, the acceptance bar for a harness with the enforcer named behind each bullet, pointers instead of copies, and the rule for where a new testing document goes. Merge-gate requiredness is stated as where to read it, never asserted (it is invisible to a non-admin token).
  • 15 dated files archived by rename into docs/archive/testing/ and indexed in docs/archive/README.md with what superseded each. Nothing deleted. docs/TESTING_GUIDE.md (2025-12, "manual > automated") is folded in and its three public links repointed.
  • PULL_MIGRATION_TESTING.md moves to docs/planning/ beside its entry point; five literal-path references repointed (two backend docstrings/log strings, one test docstring, two docs).
  • phases/ stays. The /ui-sweep skill that landed in the private skills repo today reads and refreshes docs/testing/phases/ and writes dated reports into docs/testing/ui-sweep/, so the guard admits exactly those two subdirectories and the top level stays at three files.
  • Guard tests/unit/test_2339_testing_docs_consolidated.py (+ _markdown_links.py): tracked top level == the live set; every relative link in the live set and the four entry points resolves; STRATEGY links its targets and is linked from AGENTS.md, README.md, tests/README.md, src/frontend/e2e/README.md; it copies no 4-line run from a README or the catalog; it defines no invariant and cites only resolvable ids; it names every run-full.sh tier and every test-running workflow; no live tracked file references a retired path (bytes scan over git ls-files, both link forms). Mutation battery: 15/15 red.
  • Entry points route to the strategy. AGENTS.md gains a Documentation-map row and drops a bare python -m pytest one-liner that would have run the root live suite against the operator's own instance. src/frontend/e2e/README.md no longer claims the frontend has no other automated coverage (125 Vitest specs run in frontend-build).
  • Journey catalog: harness: set for J03 and J11 (the files have existed since feat(tests,ci): journey tier + per-PR journey-smoke gate (#2335, #2336) #2403 and J11: A companion's brief reaches me where I already work — journey harness #2565); JOURNEYS.md regenerated; both harnesses registered in tests/registry.json.

Changes

39 files: 16 renames, 4 new (STRATEGY.md, the guard, its helper, the CSO diff-report pair), 19 edited. Backend hunks are a documentation path in one log string and one docstring; no behaviour changes.

Test Plan

  • pytest tests/unit/test_2339_testing_docs_consolidated.py — 24 passed (run from tests/, as CI does)
  • Neighbouring guards green: test_2337, test_2338 (JOURNEYS.md byte-equal after regeneration), test_1880, test_2008, test_2306, test_1081, test_2048, test_1990, test_credential_inject_allowlist, tests/lint_root_test_placement.py
  • Mutation battery on the guard, restored from scratch copies: 15/15 red as designed
  • git diff -M --diff-filter=D against dev: empty (renames only)
  • Enterprise-docs-guard PCRE replayed over every moved file and every new/changed live doc: 0 hits
  • Full tests/unit run: 15,503 passed, 32 skipped, 6 failed — test_1920 is the known local-only failure on a clone with the enterprise submodule mounted; the five in test_2703_skill_assign_delivery.py pass alone, pass on a clean origin/dev worktree, and pass in the 73-file span that starts with the new guard, so they are an ordering interaction with a file that sorts before it. This branch changes no code in that area; the base-vs-head regression diff here is the authoritative check.
  • journey-smoke boots a full stack on this PR by design (no path filter); frontend-e2e runs because src/frontend/e2e/README.md is in the diff

Notes for triage

  • Issue CI runs no canary invariant tests — tests/test_canary_invariants.py is outside tests/unit/ #2037's premise ("tests/test_canary_invariants.py is outside tests/unit/") looks resolved: bug: 108 test files sit in tests/ root, where no CI job runs them #1895 moved the file into tests/unit/ on 2026-08-16.
  • Private companion already on trinity-dev main (e56401b): tidy no longer routes test-*.md into docs/testing/, read-docs loads STRATEGY.md, ui-sweep's example report path follows the archive. The .claude pointer is deliberately not bumped here.
  • Two pre-existing placeholders substituted inside archived docs (a developer home-directory path, a company-domain test address), per the CLAUDE.md public-repo checklist.
  • Deferred and registered in the debt inbox: a registry-completeness guard, the catalog's stale proposal sections, the testing-agents flow refresh.

Journey Impact: none: documentation consolidation — no promise added or extended; the two harness paths recorded already existed

Fixes #2339

🤖 Generated with Claude Code

…md, the invariant catalog and JOURNEYS.md, and a guard keeps it so (#2339)

Rail R5 of the journey-coverage deck. Testing guidance lived in six places and
docs/testing/ held 17 top-level files plus a 30-file scenario tree, most of it
dated; the same coverage gap kept being rediscovered.

- docs/testing/STRATEGY.md: the method (promises, invariants, regression tests),
  the CI lanes as built, the acceptance bar for a harness with the enforcer
  behind each bullet, pointers instead of copies, and the rule for where a new
  testing document goes. Requiredness is stated as where to read it, never
  asserted.
- 15 dated plans, reports and guides archived by rename into
  docs/archive/testing/ and indexed with what superseded each; nothing deleted.
  docs/TESTING_GUIDE.md ("manual > automated", 2025-12) folded in.
- The pull-migration test record moves beside its entry point in
  docs/planning/; five literal-path references repointed.
- phases/ stays: /ui-sweep (trinity-dev, today) reads, refreshes and reports on
  it, so the guard admits exactly phases/ and ui-sweep/ as subdirectories.
- tests/unit/test_2339_testing_docs_consolidated.py pins it: the tracked top
  level is exactly the three live files; every relative link in the live set
  and the four entry points resolves; STRATEGY links its targets and is linked
  from AGENTS.md, README.md and both test READMEs; it copies no run of lines
  from a README or the catalog and defines no invariant; it names every
  run-full.sh tier and every test-running workflow; no live tracked file
  references a retired path. Mutation battery 15/15 red.
- Entry points route to the strategy: AGENTS.md gains a map row and loses a
  pytest one-liner that would have run the root live suite against the
  operator's own instance; the e2e README no longer claims the frontend has no
  other automated coverage (125 Vitest specs run in frontend-build).
- tests/journeys/catalog.yaml names the J03 and J11 harness files that have
  existed since #2403 and #2565; JOURNEYS.md regenerated; both harnesses
  registered in tests/registry.json.
- Two placeholders substituted in archived docs (a home-directory path, a
  company-domain test address).

Private companion (trinity-dev main e56401b): tidy stops routing test-*.md into
docs/testing/, read-docs loads STRATEGY.md, ui-sweep's example report path
follows the archive. The .claude pointer is not bumped here.

Fixes #2339

Co-Authored-By: Claude Fable 5.1 <[email protected]>
@webmixgamer webmixgamer added the ui PR touches the frontend UI — triggers Playwright e2e tests label Sep 13, 2026
@webmixgamer
webmixgamer requested a review from vybe September 13, 2026 22:44

@vybe vybe left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Validated via /validate-pr (Lane B): closing keyword present, all checks green incl. pytest base/head, journey-smoke and e2e; security greps clean (the two pre-existing placeholders in archived docs are substituted, not added); backend hunks are two doc-path strings only; guard + neighbours re-run locally on the head: 100 passed.

@vybe
vybe merged commit bdf6b35 into dev Sep 14, 2026
30 of 32 checks passed
@webmixgamer
webmixgamer deleted the feature/2339-testing-docs-strategy branch September 14, 2026 10:44
vybe pushed a commit that referenced this pull request Sep 14, 2026
… two token-shaped strings (#2755) — mechanical, per the merge-train note on the PR

#2758 moved exploratory-e2e-report-2026-08-14.md under docs/archive/testing/
and added a guard that fails on the live path; this PR's checks predate it.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KtVjZEsxjyz2E4x5XdQg99
vybe pushed a commit that referenced this pull request Sep 14, 2026
…#2755)

* chore(testing): ui-sweep 2026-09-13 explore+edges all areas @ 2c5cfe0 (held: no issues filed)

First full run of /ui-sweep against a freshly rebuilt local stack (backend 0.9.5-rc2, enterprise edition): 11 explore sheets covering every router path, tab id and legacy redirect, 4 edge-case sheets, one fresh-context repro pass. 65 fingerprinted findings — 1 critical, 29 medium, 35 low — each Critical/Medium validated at the source or API where the claim allowed it; 20 of 21 Mediums reproduced twice. No issues filed: the findings are held for confirmation.

Adds docs/testing/ui-sweep/ (dated report, state.json cursor + findings ledger, README) and a .gitignore for the per-run screenshot evidence, which stays local because the repo is public. Bumps the .claude submodule to ui-sweep v1.1 (whole-system mode, source-derived sheets, validation step, evidence persistence) — the retrospective of this run.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01168enK9QL4DNuVSN6taw2E

* merge-train: repoint the README to the archived report path and scrub two token-shaped strings (#2755) — mechanical, per the merge-train note on the PR

#2758 moved exploratory-e2e-report-2026-08-14.md under docs/archive/testing/
and added a guard that fails on the live path; this PR's checks predate it.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KtVjZEsxjyz2E4x5XdQg99

---------

Co-authored-by: sim <[email protected]>
Co-authored-by: Claude Fable 5.1 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ui PR touches the frontend UI — triggers Playwright e2e tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants