@ia-qa/qa-discovery 0.7.0 → 0.10.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/README.md CHANGED
@@ -82,7 +82,12 @@ Readable index: .ia-qa-discovery/capture/_overview.md
82
82
  HTML report: ia-qa-discover-report.html
83
83
  ```
84
84
 
85
- **2. Log in by hand, once.** A visible browser opens; you do whatever the app asks.
85
+ **2. Log in by hand, once — and only if you have not already.** If you logged into this app
86
+ with `ia-qa-heal login`, there is nothing to do here: `scan` picks that session up and says
87
+ so. Nobody logs into the same app twice on the same machine.
88
+
89
+ A visible browser opens; you do whatever the app asks. **Nothing to confirm afterwards** —
90
+ the window is watched, and the session is saved the moment it actually opens the app.
86
91
 
87
92
  ```console
88
93
  $ ia-qa-discover login
@@ -92,16 +97,23 @@ $ ia-qa-discover login
92
97
  Log in there however your app asks — SSO, MFA, a consent screen, all of it.
93
98
  Nothing is typed for you, and no credential is read or stored by this tool.
94
99
 
95
- When you say you are done, the browser session is saved to:
100
+ Once the session actually opens the app, it is saved to:
96
101
  .ia-qa-discovery/session.json
97
102
  That file holds live session cookies: anyone who has it is logged in as you.
98
103
 
99
- Open the browser now? [Y/n]
100
- Logged in? (leave the browser open — press Enter here when the app is showing)
104
+ 👀 Log in in the browser window. I am watching it — when the session actually opens
105
+ the app, I save it and carry on by myself. Nothing to come back and confirm here.
101
106
 
102
- ✅ Session saved — 7 cookies, 1 origin with local storage.
107
+ ✅ Session saved and checked — 7 cookies, 1 origin with local storage.
108
+ Reopened https://app.example.com/dashboard with it in a clean browser: no login wall.
103
109
  ```
104
110
 
111
+ What "checked" means here is the same thing it means in `@ia-qa/self-healing`, because it is
112
+ the same code: the session is replayed in a clean browser and only written once it reaches
113
+ somewhere the logged-out one could not. An app that keeps its token in IndexedDB leaves
114
+ nothing a session file can hold — that used to print a green tick over an empty file written
115
+ on top of one that worked.
116
+
105
117
  **3. Scan again — and hit the *second* way a page count lies.** The app navigates with React Router's `useNavigate()`, so there is not one `<a href>` to follow:
106
118
 
107
119
  ```console
@@ -241,7 +253,9 @@ Opens a **visible** browser, you log in by hand, and the session is saved for `s
241
253
 
242
254
  This verb models nothing on purpose. A declarative `auth` block describes *one shape of login* — a username field, a password field, a submit button — and every app whose login is not that shape is out of reach: federated SSO, MFA, a consent screen, a magic link, a device check. Since you perform the login yourself, all of them work.
243
255
 
244
- It refuses under CI and without a TTY: it waits for a person twice over, so a pipeline that runs it just hangs. **An agent cannot run this** — it must ask you to. For automation, point `--session` at a `storageState` your own setup already writes.
256
+ It refuses under CI and without a TTY: it waits for a person at a browser, so a pipeline that runs it just hangs. **An agent cannot run this** — it must ask you to. For automation, point `--session` at a `storageState` your own setup already writes.
257
+
258
+ And often you do not need it at all: a session saved by `ia-qa-heal login` is picked up when this project has none of its own, announced on the scan (`sessionSource: "healing"`) and never written into your config. Nobody logs into the same app twice on the same machine.
245
259
 
246
260
  The file it produces holds live cookies — whoever has it is logged in as you. The path is announced before the browser opens, `.ia-qa-discovery/.gitignore` is written on the way out, and nothing here uploads it.
247
261
 
@@ -263,6 +277,8 @@ It also reports **depth**: how many of each visited page's contracted elements y
263
277
 
264
278
  **It needs a suite that was watched running.** That means `@ia-qa/self-healing` installed, `ia-qa-heal map`, and one `ia-qa-heal run`. Without it you get a refusal that names the command, not a number: a contract means somebody configured a page, and only a watched run means a test went there. "No measurement" and "zero coverage" are different sentences, and only one of them would be true.
265
279
 
280
+ **It joins two moments, and says which one is stale.** The map compares a suite run against a scan, and those happen at different times — so both dates are printed, and when they fall on different days the consequence is spelled out. The two errors run opposite ways: a suite run older than the scan makes "not tested" include *did not exist yet*, which is no gap in your suite at all; a scan older than the run means your tests may already visit pages nobody scanned, so the gap is wider on paper than in reality. Stating the gap without the stale half is how a number gets quoted in a meeting with none of its caveats.
281
+
266
282
  **No percentage, ever.** A `34%` reads as code coverage — a ratio over a denominator a compiler guarantees. Here the denominator is uncertain by construction: a login wall, an app that navigates without `<a href>`, the page cap, states nothing opened. Counts and page names only, always beside what the scan could not see.
267
283
 
268
284
  Writes `.ia-qa-discovery/coverage-map.json` (committable, diffable) and refreshes `_overview.md`. `--report [file.html] [--open]` for the branded dossier, `--json` for the map on stdout.
@@ -313,7 +329,7 @@ The trend no single scan can reconstruct: pages, forms, API surface, and what ch
313
329
 
314
330
  This is the failure mode this tool works hardest to avoid, because every version of it *looks* like success. Three checks exist for it, and each one fires in the terminal, in `_overview.md` and in the HTML report:
315
331
 
316
- **The login wall.** An app whose catch-all route renders the login page answers HTTP 200 at *every* URL. Without a check, a scan reports "3 of 3 pages captured" having captured the same wall three times. Detection is a password field observed in the DOM — inside a `<form>` or not.
332
+ **The login wall.** An app whose catch-all route renders the login page answers HTTP 200 at *every* URL. Without a check, a scan reports "3 of 3 pages captured" having captured the same wall three times. Detection is a password field observed in the DOM — inside a `<form>` or not — and **only one the page shows when you arrive**. A field you had to click to reveal is the opposite of a wall: under `--deep`, an authenticated page with a business interaction behind a disclosure (change your password, confirm an action) was reclassified as a login wall, measured on a real portal with a valid session. The capture records which fields were revealed, so the signal ignores those.
317
333
 
318
334
  **Where the page list comes from.** Three sources, merged and deduped by path, and the report says which contributed what:
319
335
 
package/TUTORIAL.md CHANGED
@@ -136,16 +136,17 @@ the terminal has, with the same guarantees.
136
136
 
137
137
  ### Step 4.3 — The one thing your agent cannot do
138
138
 
139
- **It cannot log you in.** `login` opens a visible browser and waits for a human twice: once at
140
- the browser, once at the keyboard. That is not something an agent can perform, so it is
141
- deliberately not exposed as a tool. When the scan reports a login wall, the agent will ask
142
- *you* to run this, in your own terminal:
139
+ **It cannot log you in.** `login` opens a visible browser and waits for a human to log in.
140
+ That is not something an agent can perform, so it is deliberately not exposed as a tool. When
141
+ the scan reports a login wall, the agent will ask *you* to run this, in your own terminal:
143
142
 
144
143
  ```bash
145
144
  npx -p @ia-qa/qa-discovery ia-qa-discover login
146
145
  ```
147
146
 
148
- Then ask it to scan again.
147
+ Then ask it to scan again. **You may not need to at all:** if you already logged into this app
148
+ with `ia-qa-heal login`, the scan picks that session up on its own and says so — nobody logs
149
+ into the same app twice on the same machine.
149
150
 
150
151
  ---
151
152
 
@@ -195,6 +196,17 @@ Found 3 page(s). Capturing…
195
196
 
196
197
  ### Step 5.3 — Behind a login
197
198
 
199
+ **First, check whether you already are.** If you logged into this app with `ia-qa-heal login`
200
+ — directly, or because `ia-qa-pal tour` opened the browser for you — that session is picked up
201
+ automatically when this project has none of its own, and `scan` says so:
202
+
203
+ ```
204
+ 🔓 Scanned with the session `ia-qa-heal login` saved (.ia-qa/session.json).
205
+ No second login needed — it was picked up because this project has no session of its own.
206
+ ```
207
+
208
+ Otherwise:
209
+
198
210
  ```bash
199
211
  npx ia-qa-discover login
200
212
  ```
@@ -203,6 +215,11 @@ A visible browser opens. You log in **yourself** — SSO, MFA, a consent screen,
203
215
  device check: all of them work, because the tool models none of them. Nothing is typed for you
204
216
  and no credential is read or stored.
205
217
 
218
+ **There is nothing to confirm afterwards.** The window is watched, and the session is saved the
219
+ moment it actually opens the app — checked by replaying it in a clean browser, not by asking
220
+ you. An app that keeps its token in IndexedDB leaves nothing a session file can hold, and that
221
+ is reported instead of being written over the session you already had.
222
+
206
223
  What is saved is the browser session, in `.ia-qa-discovery/session.json`. **That file holds live
207
224
  cookies: whoever has it is logged in as you.** The tool says so before opening the browser and
208
225
  writes a `.gitignore` next to it so a commit cannot carry it away.
@@ -276,7 +293,8 @@ before it was caught, and each is now stated out loud.
276
293
 
277
294
  **1. The login wall.** Pages still showing a login form were captured — you measured the wall,
278
295
  not the app. Worse: an app whose catch-all route renders the login page answers HTTP 200 at
279
- *every* URL, so the count looks like a success. → run `login`.
296
+ *every* URL, so the count looks like a success. → scan again if you have already logged in with
297
+ `ia-qa-heal login` (that session is picked up on its own); otherwise run `login`.
280
298
 
281
299
  **2. No `<a href>` to follow.** Discovery follows links. An app navigating with React Router's
282
300
  `navigate()` or a button's `onClick` exposes none, so an 11-route app reports "1 of 1 found".
@@ -519,11 +537,13 @@ npx ia-qa-discover-ai plan --report --open # the branded dossier, in a browser
519
537
  **"Found 1 page" on an app I know has twenty.** Section 7, case 2 — the app navigates without
520
538
  links. Declare the routes in `config.json` → `pages`.
521
539
 
522
- **Everything is the login page.** Section 7, case 1. Run `login`, then scan again.
540
+ **Everything is the login page.** Section 7, case 1. If you already logged in with
541
+ `ia-qa-heal login`, just scan again — that session is picked up automatically. Otherwise run
542
+ `login`, then scan again.
523
543
 
524
544
  **`login` says it refuses.** It refuses without a terminal and under CI, because it waits for a
525
- person twice. That is also why an AI agent cannot run it. For a pipeline, point `--session` at a
526
- `storageState` your own setup writes.
545
+ person at a browser. That is also why an AI agent cannot run it. For a pipeline, point
546
+ `--session` at a `storageState` your own setup writes.
527
547
 
528
548
  **"Nothing to show yet" from `coverage`.** Your suite has never been watched running. Run
529
549
  `npx ia-qa-heal run` or `npx -p @ia-qa/pal ia-qa-pal tour --suite`. This is not zero coverage — it
@@ -69,13 +69,21 @@ export interface CapturedForm {
69
69
  }
70
70
  export declare const PAGE_CAPTURE_SCHEMA = "qa-discovery-page@1";
71
71
  /**
72
- * Does this capture hold a password field — in a `<form>` or loose?
72
+ * Does this page **show** a password field when you arrive on it?
73
73
  *
74
74
  * Lives beside the type rather than in whichever consumer wanted it first, because two
75
- * readers now depend on answering it the same way: `loginWallPages` (is this scan looking at
76
- * a wall instead of the app?) and `generate` (would this spec assert a login form under
75
+ * readers depend on answering it the same way: `loginWallPages` (is this scan looking at a
76
+ * wall instead of the app?) and `generate` (would this spec assert a login form under
77
77
  * another page's name?). Both halves are load-bearing — a React login that submits in JS
78
78
  * often has no `<form>` at all, so reading `forms` alone misses exactly the wall this is for.
79
+ *
80
+ * **A field carrying `via` is excluded, and that word is the whole fix.** `--deep` clicks one
81
+ * level of disclosures and merges what they reveal into `looseFields`, so an authenticated
82
+ * product page with a password behind a business interaction — change your password, confirm
83
+ * an action — was reclassified as a login wall the moment the scan opened it. Measured on a
84
+ * real portal: the same page, same session, captured normally in a standard scan and as a
85
+ * wall under `--deep`. A wall is what a page shows you when you arrive; what you can reveal
86
+ * by clicking is the opposite of that, and the capture already records which is which.
79
87
  */
80
88
  export declare function hasPasswordField(page: Pick<PageCapture, 'forms' | 'looseFields'>): boolean;
81
89
  export interface PageCapture {
@@ -8,17 +8,25 @@ const network_1 = require("../network");
8
8
  const explore_1 = require("../explore");
9
9
  exports.PAGE_CAPTURE_SCHEMA = 'qa-discovery-page@1';
10
10
  /**
11
- * Does this capture hold a password field — in a `<form>` or loose?
11
+ * Does this page **show** a password field when you arrive on it?
12
12
  *
13
13
  * Lives beside the type rather than in whichever consumer wanted it first, because two
14
- * readers now depend on answering it the same way: `loginWallPages` (is this scan looking at
15
- * a wall instead of the app?) and `generate` (would this spec assert a login form under
14
+ * readers depend on answering it the same way: `loginWallPages` (is this scan looking at a
15
+ * wall instead of the app?) and `generate` (would this spec assert a login form under
16
16
  * another page's name?). Both halves are load-bearing — a React login that submits in JS
17
17
  * often has no `<form>` at all, so reading `forms` alone misses exactly the wall this is for.
18
+ *
19
+ * **A field carrying `via` is excluded, and that word is the whole fix.** `--deep` clicks one
20
+ * level of disclosures and merges what they reveal into `looseFields`, so an authenticated
21
+ * product page with a password behind a business interaction — change your password, confirm
22
+ * an action — was reclassified as a login wall the moment the scan opened it. Measured on a
23
+ * real portal: the same page, same session, captured normally in a standard scan and as a
24
+ * wall under `--deep`. A wall is what a page shows you when you arrive; what you can reveal
25
+ * by clicking is the opposite of that, and the capture already records which is which.
18
26
  */
19
27
  function hasPasswordField(page) {
20
28
  return (page.forms.some((f) => f.fields.some((fl) => fl.type === 'password')) ||
21
- page.looseFields.some((fl) => fl.type === 'password'));
29
+ page.looseFields.some((fl) => fl.type === 'password' && !fl.via?.length));
22
30
  }
23
31
  /**
24
32
  * Capture one page's structural surface: meta/headings/forms via a single
@@ -1 +1 @@
1
- {"version":3,"file":"page.js","sourceRoot":"","sources":["../../src/capture/page.ts"],"names":[],"mappings":";;;AA8FA,4CAKC;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QAED,0EAA0E;QAC1E,6EAA6E;QAC7E,yEAAyE;QACzE,OAAO;YACL,MAAM,EAAE,2BAAmB;YAC3B,IAAI,EAAE,SAAS,CAAC,IAAI;YACpB,GAAG,EAAE,IAAA,0BAAgB,EAAC,WAAW,EAAE,UAAU,CAAC,CAAC,GAAG;YAClD,QAAQ,EAAE,IAAA,0BAAgB,EAAC,QAAQ,EAAE,UAAU,CAAC,CAAC,GAAG;YACpD,MAAM,EAAE,SAAS,CAAC,MAAM;YACxB,UAAU,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;YACpC,IAAI,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE;YAC5B,IAAI,EAAE,SAAS,CAAC,IAAI;YACpB,QAAQ,EAAE,SAAS,CAAC,QAAQ;YAC5B,KAAK,EAAE,SAAS,CAAC,KAAK;YACtB,WAAW;YACX,QAAQ;YACR,WAAW;SACZ,CAAC;IACJ,CAAC;YAAS,CAAC;QACT,IAAI,MAAM;YAAE,MAAM,EAAE,CAAC;IACvB,CAAC;AACH,CAAC"}
package/dist/cli/args.js CHANGED
@@ -21,7 +21,7 @@ exports.KNOWN_FLAGS = {
21
21
  '--report',
22
22
  '--open',
23
23
  ],
24
- login: ['--url', '--session'],
24
+ login: ['--url', '--session', '--wait'],
25
25
  history: ['--json', '--limit'],
26
26
  coverage: ['--json', '--report', '--open'],
27
27
  generate: ['--json', '--out', '--force', '--include-login-walls', '--include-error-pages'],
@@ -1 +1 @@
1
- {"version":3,"file":"args.js","sourceRoot":"","sources":["../../src/cli/args.ts"],"names":[],"mappings":";;;AAyBA,gDAQC;AAjCD,sGAAsG;AACzF,QAAA,WAAW,GAAsC;IAC5D,KAAK,EAAE,CAAC,WAAW,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,SAAS,CAAC;IAC7D,IAAI,EAAE;QACJ,SAAS;QACT,OAAO;QACP,aAAa;QACb,eAAe;QACf,WAAW;QACX,cAAc;QACd,cAAc;QACd,QAAQ;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AAO,EAAE,CAAC,QAAQ,EAAE,SAAS,CAAC;IAC9B,QAAQ,EAAE,CAAC,QAAQ,EAAE,UAAU,EAAE,QAAQ,CAAC;IAC1C,QAAQ,EAAE,CAAC,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,uBAAuB,EAAE,uBAAuB,CAAC;CAC3F,CAAC;AAEF,SAAgB,kBAAkB,CAAC,OAAe,EAAE,IAAc;IAChE,MAAM,KAAK,GAAG,mBAAW,CAAC,OAAO,CAAC,CAAC;IACnC,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO;IAChC,KAAK,MAAM,CAAC,IAAI,IAAI,EAAE,CAAC;QACrB,IAAI,CAAC,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC;YAAE,SAAS;QACjC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;YAAE,SAAS;QAChC,MAAM,IAAI,KAAK,CAAC,iBAAiB,CAAC,yBAAyB,OAAO,kDAAkD,CAAC,CAAC;IACxH,CAAC;AACH,CAAC"}
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- declare const HELP = "ia-qa-discover \u2014 deterministic surface reconnaissance for a web app\n\nF1 of QA Discovery: crawl an app's same-origin pages and capture what each one\nis structurally about \u2014 title, headings, forms, and observed API calls. No\nLLM, no verdict: this is recon, not a gate. Runs entirely on your machine;\nnothing is uploaded anywhere.\n\n[FOR AI AGENTS] You are driving this for a human. Run `scan` to capture the\napp's surface, then read .ia-qa-discovery/capture/surface.json (the index) and\nthe per-page files it points at \u2014 that is the evidence for anything you\nreport about this app. Never assert a page's purpose or risk from the URL\nalone; ground it in the captured meta/headings/forms/apiCalls. Never read a\npage count as coverage: if scan warns that pages still show a login form, you\nmeasured the wall, not the app. You CANNOT run `login` \u2014 it waits for a human\nat a browser; ask them to run it, then scan again.\n`coverage` answers \"what does their suite NOT test\" \u2014 but only from a suite that was\nwatched running (one `ia-qa-heal run`, or one `ia-qa-pal tour --suite`). If it says there is no\nmeasurement, report that, never \"the suite covers nothing\": a contract means someone\nconfigured a page, only a watched run means a test went there.\n\nUsage:\n ia-qa-discover login Open a visible browser, log in by hand, keep the\n session (.ia-qa-discovery/session.json) for scan\n to reuse. The general answer to a login wall: it\n models nothing, so SSO, MFA, a consent screen or\n a magic link all work \u2014 you do them.\n Needs a terminal, refuses under CI. The file holds\n live cookies: gitignored, stays on this machine.\n --url <path> page to open (default: your baseUrl)\n --session <f> where to write it\n Already have a storageState (a Playwright globalSetup\n writes one)? Skip this verb: point scan at it with\n --session <file> or \"session\" in config.json.\n ia-qa-discover scan [url] Crawl same-origin pages from <url> (or the saved\n baseUrl) and capture each page's structure.\n Writes .ia-qa-discovery/capture/, diffs against\n the previous run, appends history.jsonl.\n --depth <n> crawl link-depth (default 2)\n --max <n> page cap (default 60)\n --deep also open menus, tabs and dialogs one level\n down and capture the fields they reveal. Every\n non-GET request is blocked for the duration,\n so a click cannot mutate anything server-side.\n --deep-budget <n> max controls clicked per page (default 60)\n --no-sitemap do not read sitemap.xml / robots.txt\n --no-reveal do not open menus/dropdowns for hidden links\n --strict-host treat www./apex as different hosts\n --session <file> reuse an existing storageState (login) file\n --no-network skip API/network-call capture this run\n --network-threshold <n> shared-call promotion threshold 0-1 (default 0.6)\n --save persist this baseUrl to config.json\n --json machine-readable summary on stdout\n --report [file.html] branded ia-qa.com HTML dossier of the\n app (default ia-qa-discover-report.html)\n --open open that report in the browser\n ia-qa-discover coverage What your test suite does NOT test. Compares the\n pages this scan found against the pages your suite\n was OBSERVED visiting, ranks the gap by what each\n page takes as input, and writes coverage-map.json.\n Reads local files only \u2014 no browser, no network.\n Needs one watched run of your suite \u2014\n \"ia-qa-heal run\" or \"ia-qa-pal tour --suite\":\n without a watched run there is no measurement, and\n it says so instead of showing a number.\n Declare pages you deliberately do not test in\n \"outOfScope\" in config.json \u2014 they stay counted\n and named, never silently dropped.\n --json machine-readable map on stdout\n --report [file.html] branded HTML dossier with the gap\n (default ia-qa-discover-coverage.html)\n --open open that report in the browser\n ia-qa-discover generate [page\u2026] A starting Playwright suite for the pages nothing\n tests \u2014 one file per page, into its own directory.\n Every locator names an element the healing contract\n holds, so the file is REPAIRED when the app moves\n instead of going red. A field with no test id, id or\n name is left out and says so: its selector would be\n positional, which nobody can test reliably.\n Proposals \u2014 nothing is added to your suite, and the\n assertions stay yours (the app declares what it\n accepts, never what it promises).\n With no page, it generates for the coverage gap,\n minus the pages captured as a login wall or an\n error \u2014 those specs would assert a login form or\n a 404 under a feature's name. They are named, and\n naming one generates for it anyway.\n --out <dir> where to write (default\n .ia-qa-discovery/generated/)\n --force replace files already there\n --include-login-walls, --include-error-pages\n generate for those too\n --json machine-readable summary on stdout\n ia-qa-discover skill This CLI's agent instructions: the verb for each\n question, what every refusal means, and what an\n agent must never do. Read them before driving\n anything else here.\n --print write them to stdout and stop\n --install write .claude/skills/ia-qa-discover/\n --user into ~/ instead of this project\n --dir <d> into another project root\n --force overwrite an edited copy\n ia-qa-discover history Recorded scan runs \u2014 pages/forms/API-surface trend.\n --json --limit <n> (default 500)\n ia-qa-discover version Print the installed version (also --version, -v)\n ia-qa-discover help Show this help\n\nGlobal:\n --config <dir> Resolve .ia-qa-discovery/ under <dir> instead of the\n current directory. Also IAQA_DISCOVERY_CONFIG_DIR=<dir>.\n";
2
+ declare const HELP = "ia-qa-discover \u2014 deterministic surface reconnaissance for a web app\n\nF1 of QA Discovery: crawl an app's same-origin pages and capture what each one\nis structurally about \u2014 title, headings, forms, and observed API calls. No\nLLM, no verdict: this is recon, not a gate. Runs entirely on your machine;\nnothing is uploaded anywhere.\n\n[FOR AI AGENTS] You are driving this for a human. Run `scan` to capture the\napp's surface, then read .ia-qa-discovery/capture/surface.json (the index) and\nthe per-page files it points at \u2014 that is the evidence for anything you\nreport about this app. Never assert a page's purpose or risk from the URL\nalone; ground it in the captured meta/headings/forms/apiCalls. Never read a\npage count as coverage: if scan warns that pages still show a login form, you\nmeasured the wall, not the app. You CANNOT run `login` \u2014 it waits for a human\nat a browser; ask them to run it, then scan again.\n`coverage` answers \"what does their suite NOT test\" \u2014 but only from a suite that was\nwatched running (one `ia-qa-heal run`, or one `ia-qa-pal tour --suite`). If it says there is no\nmeasurement, report that, never \"the suite covers nothing\": a contract means someone\nconfigured a page, only a watched run means a test went there.\n\nUsage:\n ia-qa-discover login Open a visible browser, log in by hand, keep the\n session (.ia-qa-discovery/session.json) for scan\n to reuse. The general answer to a login wall: it\n models nothing, so SSO, MFA, a consent screen or\n a magic link all work \u2014 you do them.\n Needs a terminal, refuses under CI. The file holds\n live cookies: gitignored, stays on this machine.\n Nothing to confirm afterwards: the window is\n watched and the session is saved the moment it\n actually opens the app. Already logged in with\n ia-qa-heal login? You do not need this at all \u2014\n scan picks that session up and says so.\n --wait <s> how long to watch (0 = press Enter)\n --url <path> page to open (default: your baseUrl)\n --session <f> where to write it\n Already have a storageState (a Playwright globalSetup\n writes one)? Skip this verb: point scan at it with\n --session <file> or \"session\" in config.json.\n ia-qa-discover scan [url] Crawl same-origin pages from <url> (or the saved\n baseUrl) and capture each page's structure.\n Writes .ia-qa-discovery/capture/, diffs against\n the previous run, appends history.jsonl.\n --depth <n> crawl link-depth (default 2)\n --max <n> page cap (default 60)\n --deep also open menus, tabs and dialogs one level\n down and capture the fields they reveal. Every\n non-GET request is blocked for the duration,\n so a click cannot mutate anything server-side.\n --deep-budget <n> max controls clicked per page (default 60)\n --no-sitemap do not read sitemap.xml / robots.txt\n --no-reveal do not open menus/dropdowns for hidden links\n --strict-host treat www./apex as different hosts\n --session <file> reuse an existing storageState (login) file\n --no-network skip API/network-call capture this run\n --network-threshold <n> shared-call promotion threshold 0-1 (default 0.6)\n --save persist this baseUrl to config.json\n --json machine-readable summary on stdout\n --report [file.html] branded ia-qa.com HTML dossier of the\n app (default ia-qa-discover-report.html)\n --open open that report in the browser\n ia-qa-discover coverage What your test suite does NOT test. Compares the\n pages this scan found against the pages your suite\n was OBSERVED visiting, ranks the gap by what each\n page takes as input, and writes coverage-map.json.\n Reads local files only \u2014 no browser, no network.\n Needs one watched run of your suite \u2014\n \"ia-qa-heal run\" or \"ia-qa-pal tour --suite\":\n without a watched run there is no measurement, and\n it says so instead of showing a number.\n Declare pages you deliberately do not test in\n \"outOfScope\" in config.json \u2014 they stay counted\n and named, never silently dropped.\n --json machine-readable map on stdout\n --report [file.html] branded HTML dossier with the gap\n (default ia-qa-discover-coverage.html)\n --open open that report in the browser\n ia-qa-discover generate [page\u2026] A starting Playwright suite for the pages nothing\n tests \u2014 one file per page, into its own directory.\n Every locator names an element the healing contract\n holds, so the file is REPAIRED when the app moves\n instead of going red. A field with no test id, id or\n name is left out and says so: its selector would be\n positional, which nobody can test reliably.\n Proposals \u2014 nothing is added to your suite, and the\n assertions stay yours (the app declares what it\n accepts, never what it promises).\n With no page, it generates for the coverage gap,\n minus the pages captured as a login wall or an\n error \u2014 those specs would assert a login form or\n a 404 under a feature's name. They are named, and\n naming one generates for it anyway.\n --out <dir> where to write (default\n .ia-qa-discovery/generated/)\n --force replace files already there\n --include-login-walls, --include-error-pages\n generate for those too\n --json machine-readable summary on stdout\n ia-qa-discover skill This CLI's agent instructions: the verb for each\n question, what every refusal means, and what an\n agent must never do. Read them before driving\n anything else here.\n --print write them to stdout and stop\n --install write .claude/skills/ia-qa-discover/\n --user into ~/ instead of this project\n --dir <d> into another project root\n --force overwrite an edited copy\n ia-qa-discover history Recorded scan runs \u2014 pages/forms/API-surface trend.\n --json --limit <n> (default 500)\n ia-qa-discover version Print the installed version (also --version, -v)\n ia-qa-discover help Show this help\n\nGlobal:\n --config <dir> Resolve .ia-qa-discovery/ under <dir> instead of the\n current directory. Also IAQA_DISCOVERY_CONFIG_DIR=<dir>.\n";
3
3
  declare function verbHelp(command: string | undefined): string | null;
4
4
  declare function main(): Promise<void>;
5
5
  export { HELP, verbHelp, main };
package/dist/cli/index.js CHANGED
@@ -42,6 +42,12 @@ Usage:
42
42
  a magic link all work — you do them.
43
43
  Needs a terminal, refuses under CI. The file holds
44
44
  live cookies: gitignored, stays on this machine.
45
+ Nothing to confirm afterwards: the window is
46
+ watched and the session is saved the moment it
47
+ actually opens the app. Already logged in with
48
+ ia-qa-heal login? You do not need this at all —
49
+ scan picks that session up and says so.
50
+ --wait <s> how long to watch (0 = press Enter)
45
51
  --url <path> page to open (default: your baseUrl)
46
52
  --session <f> where to write it
47
53
  Already have a storageState (a Playwright globalSetup
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/cli/index.ts"],"names":[],"mappings":";;;;AAwOe,4BAAQ;AAAE,oBAAI;AAvO7B,sCAAuC;AACvC,iCAAyD;AACzD,iCAAiC;AACjC,mCAAmC;AACnC,uCAAuC;AACvC,yCAAyC;AACzC,yCAAyC;AACzC,mCAAmC;AAEnC,qEAAqE;AACrE,MAAM,OAAO,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC,OAAiB,CAAC;AAEhE,MAAM,IAAI,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6GZ,CAAC;AA8GO,oBAAI;AA5Gb,SAAS,gBAAgB,CAAC,IAAc;IACtC,MAAM,IAAI,GAAa,EAAE,CAAC;IAC1B,IAAI,GAAuB,CAAC;IAC5B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACrC,MAAM,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;QAClB,IAAI,CAAC,KAAK,UAAU,EAAE,CAAC;YACrB,MAAM,IAAI,GAAG,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;YACzB,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;gBAC/C,MAAM,IAAI,KAAK,CAAC,8DAA8D,CAAC,CAAC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oBAAoB,OAAO,SAAS,IAAI,EAAE,CAAC,CAAC;YAC1D,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACpB,CAAC;AACH,CAAC;AAED;;;;;;;GAOG;AACH,IAAI,OAAO,CAAC,IAAI,KAAK,MAAM;IAAE,GAAG,EAAE,CAAC;AAEnC,SAAS,GAAG;IACV,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,GAAY,EAAE,EAAE;QAC5B,OAAO,CAAC,KAAK,CAAC,OAAO,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACzE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAClB,CAAC,CAAC,CAAC;AACL,CAAC"}
package/dist/cli/login.js CHANGED
@@ -36,7 +36,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.runLogin = runLogin;
37
37
  const fs = __importStar(require("fs"));
38
38
  const path = __importStar(require("path"));
39
- const readline = __importStar(require("readline/promises"));
40
39
  const self_healing_1 = require("@ia-qa/self-healing");
41
40
  const config_1 = require("../config");
42
41
  /**
@@ -107,54 +106,36 @@ async function runLogin(args) {
107
106
  return;
108
107
  }
109
108
  const file = (0, config_1.sessionTarget)(config, explicit).file;
110
- console.log(`\n🔑 ia-qa-discover login`);
111
- console.log(` Opens a visible browser at ${target}.`);
112
- console.log(` Log in there however your app asks — SSO, MFA, a consent screen, all of it.`);
113
- console.log(` Nothing is typed for you, and no credential is read or stored by this tool.\n`);
114
- console.log(` When you say you are done, the browser session is saved to:`);
115
- console.log(` ${file}`);
116
- console.log(` That file holds live session cookies: anyone who has it is logged in as you.`);
117
- console.log(` It stays on this machine — nothing here uploads it — and`);
118
- console.log(` \`${config_1.CONFIG_DIR}/.gitignore\` is written so a commit cannot carry it.\n`);
119
- const rl = readline.createInterface({ input: process.stdin, output: process.stdout });
120
- try {
121
- const go = (await rl.question('Open the browser now? [Y/n] ')).trim().toLowerCase();
122
- if (go === 'n' || go === 'no') {
123
- console.log('Nothing opened, nothing written.');
124
- process.exitCode = 1;
125
- return;
126
- }
127
- const { browser, using } = await (0, self_healing_1.launchBrowser)({ headed: true });
128
- console.log(`🌐 Using ${using} (visible window)`);
129
- try {
130
- const locale = config?.locale || process.env.IAQA_LOCALE;
131
- const context = await browser.newContext(locale ? { locale } : {});
132
- const page = await context.newPage();
133
- await page.goto(target, { waitUntil: 'domcontentloaded', timeout: 60000 });
134
- await rl.question('Logged in? (leave the browser open — press Enter here when the app is showing) ');
135
- // Saved as-is, on the human's word. Nothing here can tell "logged in" from
136
- // "still on step 2 of the SSO" for an arbitrary app, and claiming otherwise
137
- // would be the false green this package exists to avoid. `scan` finds out
138
- // for real — it warns when the pages it captured still show a login form.
139
- const landed = page.url();
140
- fs.mkdirSync(path.dirname(file), { recursive: true });
141
- const state = await context.storageState({ path: file });
142
- writeSessionGitignore();
143
- const origins = state.origins?.length || 0;
144
- console.log(`\n✅ Session saved — ${state.cookies.length} cookies, ${origins} ${origins === 1 ? 'origin' : 'origins'} with local storage.`);
145
- console.log(` ${file}`);
146
- console.log(` Browser was on ${landed} when it was taken.`);
147
- console.log(` \`ia-qa-discover scan\` will reuse it automatically. A saved session is a`);
148
- console.log(` local artefact with a shelf life — when it expires, scan sees the login`);
149
- console.log(` wall again and says to re-run this.`);
150
- }
151
- finally {
152
- await browser.close();
153
- }
154
- }
155
- finally {
156
- rl.close();
109
+ const locale = config?.locale || process.env.IAQA_LOCALE;
110
+ // Same flag and same default as the sibling: the watch replaces "press Enter", and 0
111
+ // restores the manual step for an app whose login cannot be observed from the outside.
112
+ const waitIdx = args.indexOf('--wait');
113
+ const waitSeconds = waitIdx !== -1 ? Number(args[waitIdx + 1]) : 600;
114
+ if (waitIdx !== -1 && (!Number.isFinite(waitSeconds) || waitSeconds < 0)) {
115
+ console.error('❌ --wait needs a number of seconds (0 turns the watch off).');
116
+ process.exitCode = 2;
117
+ return;
157
118
  }
119
+ // Everything from the announcement to the write is `performLogin`, imported from
120
+ // `@ia-qa/self-healing`. What stood here was a hand-written twin of that verb as it was
121
+ // BEFORE both of its corrections: it asked "Logged in? press Enter", then called
122
+ // `storageState({ path })` — which writes before anything is checked — and printed
123
+ // `✅ Session saved — N cookies`. So an app keeping its token in IndexedDB got a green
124
+ // tick over an empty file written on top of one that worked, which is the exact defect
125
+ // the sibling had already fixed and documented. A doctrine repaired in one copy only is
126
+ // not a doctrine, and "does this session open the app" is the same question here.
127
+ //
128
+ // What stays local is what is genuinely narrower: this package's paths, its URL rules,
129
+ // its own .gitignore and its own refusals above.
130
+ await (0, self_healing_1.performLogin)({
131
+ verb: `ia-qa-discover login`,
132
+ target,
133
+ file,
134
+ gitignore: `${config_1.CONFIG_DIR}/.gitignore`,
135
+ writeGitignore: writeSessionGitignore,
136
+ contextOptions: locale ? { locale } : {},
137
+ waitSeconds,
138
+ });
158
139
  }
159
140
  /**
160
141
  * `.ia-qa-discovery/.gitignore`, scoped to the one file in there that is a
@@ -1 +1 @@
1
- {"version":3,"file":"login.js","sourceRoot":"","sources":["../../src/cli/login.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CA,4BAuGC;AAjJD,uCAAyB;AACzB,2CAA6B;AAC7B,4DAA8C;AAC9C,sDAAoD;AACpD,sCAQmB;AAEnB;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACI,KAAK,UAAU,QAAQ,CAAC,IAAc;IAC3C,IAAI,OAAO,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC;QACnB,OAAO,CAAC,KAAK,CACX,kDAAkD;YAChD,mFAAmF;YACnF,iFAAiF;YACjF,kEAAkE,CACrE,CAAC;QACF,OAAO,CAAC,QAAQ,GAAG,CAAC,CAAC;QACrB,OAAO;IACT,CAAC;IACD,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,KAAK,EAAE,CAAC;QACzB,OAAO,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,EAAE,CAAC;QAC1E,IAAI,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,EAAE,KAAK,yBAAgB,CAAC;YAAE,OAAO;QAC/E,MAAM,GAAG,GAAG,QAAQ,IAAI,CAAC,QAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC;QAC7D,EAAE,CAAC,aAAa,CAAC,IAAI,EAAE,QAAQ,GAAG,GAAG,GAAG,yBAAgB,GAAG,IAAI,EAAE,MAAM,CAAC,CAAC;IAC3E,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,OAAO,CAAC,IAAI,CACV,wBAAwB,IAAI,KAAK,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,MAAM;YACrF,aAAa,mBAAU,IAAI,yBAAgB,sDAAsD,CACpG,CAAC;IACJ,CAAC;AACH,CAAC"}
package/dist/cli/scan.js CHANGED
@@ -141,7 +141,12 @@ async function runScan(args) {
141
141
  deepBudget: intArg(args, '--deep-budget', 500),
142
142
  networkThreshold: floatArg(args, '--network-threshold'),
143
143
  save: args.includes('--save'),
144
- onProgress: json ? undefined : log,
144
+ // Human lines go to **stderr** under `--json`, never nowhere. stdout has to stay one
145
+ // parseable document — that is the rule, and it is the rule `ia-qa-heal run --json`
146
+ // already follows by diverting rather than silencing. Silencing it here meant a deep
147
+ // scan measured at ~28 minutes said absolutely nothing while it worked, which is
148
+ // indistinguishable from a hung command and makes a CI timeout impossible to set.
149
+ onProgress: json ? (line) => process.stderr.write(`${line}\n`) : log,
145
150
  });
146
151
  const classification = (0, classificationView_1.classificationFor)(result.pages);
147
152
  const wantedReport = reportPath(args);
@@ -202,7 +207,11 @@ async function runScan(args) {
202
207
  `(${result.loginWall.join(', ')}).`);
203
208
  console.log(` You are very likely looking at the login wall, not the app — a page count is not coverage.`);
204
209
  console.log(result.session
205
- ? ` The saved session (${result.session}) did not get past it: it may have expired. Re-run \`ia-qa-discover login\`.`
210
+ ? // Whoever wrote the session is who should refresh it: telling someone to run this
211
+ // package's `login` over a file the sibling owns leaves two sessions for the same
212
+ // app and refreshes the one that was not being used.
213
+ ` The saved session (${result.session}) did not get past it: it may have expired.\n` +
214
+ ` Refresh it: \`${result.sessionSource === 'healing' ? 'ia-qa-heal login' : 'ia-qa-discover login'}\`.`
206
215
  : ` Run \`ia-qa-discover login\` to log in by hand once, then scan again.`);
207
216
  }
208
217
  else if (result.loginWall.length === 1 && !result.session) {
@@ -214,7 +223,14 @@ async function runScan(args) {
214
223
  console.log(` Run \`ia-qa-discover login\` to log in by hand once, then scan again.`);
215
224
  }
216
225
  else if (result.session) {
217
- console.log(`\n🔓 Scanned with the saved session (${result.session}).`);
226
+ // A borrowed session is named as borrowed. It was not asked for in this command, and a
227
+ // credential used without being asked for is one that has to be announced — the
228
+ // alternative is somebody reading an authenticated surface as the public one, or the
229
+ // reverse. Nothing leaves the machine either way; the announcement is about the reader.
230
+ console.log(result.sessionSource === 'healing'
231
+ ? `\n🔓 Scanned with the session \`ia-qa-heal login\` saved (${result.session}).\n` +
232
+ ` No second login needed — it was picked up because this project has no session of its own.`
233
+ : `\n🔓 Scanned with the saved session (${result.session}).`);
218
234
  }
219
235
  // A loaded page is one state of a page. Where the input surface hides behind
220
236
  // clicks, the field count above is honest only if it says so.
@@ -1 +1 @@
1
- {"version":3,"file":"scan.js","sourceRoot":"","sources":["../../src/cli/scan.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAQA,0CAWC;AAED,8BAMC;AAED,wBASC;AAED,4BASC;AAWD,gCAMC;AAGD,sCAUC;AAED,0BAkIC;AAnND,uCAAyB;AACzB,2CAA6B;AAC7B,iDAAsC;AACtC,kCAAkC;AAClC,8CAAiD;AACjD,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AAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,WAAW,EAAE,QAAQ,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACtF,MAAM,SAAS,GAAG,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC,MAAM,CAAC;QAC9E,OAAO,CAAC,GAAG,CAAC,sBAAsB,QAAQ,gBAAgB,QAAQ,+CAA+C,CAAC,CAAC;QACnH,IAAI,QAAQ,GAAG,CAAC,EAAE,CAAC;YACjB,OAAO,CAAC,GAAG,CAAC,QAAQ,QAAQ,8FAA8F,CAAC,CAAC;QAC9H,CAAC;QACD,IAAI,SAAS,GAAG,CAAC;YAAE,OAAO,CAAC,GAAG,CAAC,QAAQ,SAAS,iEAAiE,CAAC,CAAC;IACrH,CAAC;IAED,OAAO,CAAC,GAAG,CAAC,gBAAgB,MAAM,CAAC,WAAW,EAAE,CAAC,CAAC;IAClD,OAAO,CAAC,GAAG,CAAC,mBAAmB,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE,cAAc,CAAC,EAAE,CAAC,CAAC;IAC9F,IAAI,aAAa;QAAE,OAAO,CAAC,GAAG,CAAC,mBAAmB,aAAa,EAAE,CAAC,CAAC;IAEnE,6EAA6E;IAC7E,KAAK,MAAM,IAAI,IAAI,IAAA,8BAAgB,EAAC,IAAA,4BAAc,EAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QAAE,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;AACvF,CAAC"}
package/dist/config.d.ts CHANGED
@@ -97,7 +97,13 @@ export declare function loadConfig(cwd?: string): DiscoveryConfig;
97
97
  export declare function saveConfig(config: DiscoveryConfig, cwd?: string): string;
98
98
  export declare function configExists(cwd?: string): boolean;
99
99
  export declare function sessionPath(cwd?: string): string;
100
- export type SessionSource = 'flag' | 'env' | 'config' | 'login';
100
+ /**
101
+ * Where `@ia-qa/self-healing` keeps its session, resolved against THIS package's project
102
+ * root rather than through its module-global `baseDir` — the two packages keep separate
103
+ * state directories under one project, and `--config` must move both the same way.
104
+ */
105
+ export declare function healingSessionPath(cwd?: string): string;
106
+ export type SessionSource = 'flag' | 'env' | 'config' | 'login' | 'healing';
101
107
  export interface SessionChoice {
102
108
  file: string;
103
109
  source: SessionSource;