mr-onion

Test cases: Introspect (INT)

Section 3.4 of the test plan, which keeps the app overview, the feature status, the known limitations and the index of areas. Since TFP-253 each area’s cases are in a file of their own; a ticket names the area it touches.

ID Test Expected Result Status
INT-01 Content rules and content-aware generation state (automated: “covers the content rules section and content-aware generation state”) Per-page introspection results (elements, roles, content) are reflected in the content rules section and inform content-aware generation. ✅
INT-02 Manual: introspect a page with no actionable elements Introspection completes without error and reports an empty or near-empty actionable-element set rather than failing. ⬜
INT-03 Introspect executes with no external backend configured (automated: tests/regression/mr-onion.sections.spec.ts — “executes generate, run, crawl, introspect, and save-suite without an external backend configured”) POST /api/introspect succeeds synchronously and returns at least one inspected page, with no environment variable set beyond .env.development. ✅
INT-04 Actionable elements report isVisible Every discovered actionable element carries a boolean isVisible. Evidence. ✅
INT-05 Actionable elements report ARIA state and toggle-group membership Every discovered actionable element carries ariaPressed/ariaSelected/ariaChecked/ariaExpanded/groupId as string \| null. Evidence. ✅
INT-06 Pages report drag-and-drop targets Every page carries a dragDropTargets array with isVisible/isDraggableSource/isDropTarget booleans and a string tagName. Evidence. ✅
INT-07 Per-baseUrl dependency map Each real outbound dependency by host and kind (XHR/fetch, form action, third-party script, iframe, redirect, cookie), deduped. Evidence. ✅
INT-08 Per-baseUrl walkable site graph Pages as nodes; each edge names the element that navigates (link, form-submit, action), from existing introspect output. Evidence. ✅
INT-09 Candidate journeys: every simple path of at most 6 hops ending in a form-submit edge (automatic), plus config-named flows ({ label, entryPath, exitPath }), deduped by page sequence, named-first then shortest-first, capped at 20 Ranked journeys on inspectPages and /api/introspect. Evidence. ✅
INT-10 Inspection reads a page only once it has drawn After network idle, inspection also waits for 1 s of quiet - no request in flight and no element added, removed or re-texted - within the same 10 s bound, and is never failed for the wait. Evidence. ✅
INT-11 Introspection records controls as they are Roles by input type (ARIA in HTML): search is a searchbox (a combobox with a list), number a spinbutton, range a slider, image/submit/button/reset a button, text-like fields with a list a combobox; text, email, tel, url and password stay textbox. Evidence. ✅