@testsprite/testsprite-cli 0.15.0 → 0.17.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 +53 -141
- package/dist/commands/agent.d.ts +12 -4
- package/dist/commands/agent.js +55 -65
- package/dist/commands/auth.d.ts +6 -10
- package/dist/commands/auth.js +44 -56
- package/dist/commands/ci.d.ts +23 -100
- package/dist/commands/ci.js +297 -489
- package/dist/commands/completion.js +2 -1
- package/dist/commands/conversation.d.ts +27 -0
- package/dist/commands/conversation.js +702 -0
- package/dist/commands/doctor.d.ts +5 -1
- package/dist/commands/doctor.js +130 -34
- package/dist/commands/init.d.ts +4 -45
- package/dist/commands/init.js +116 -68
- package/dist/commands/project-env.d.ts +62 -2
- package/dist/commands/project-env.js +426 -53
- package/dist/commands/project-sign-in.d.ts +0 -48
- package/dist/commands/project-sign-in.js +1 -224
- package/dist/commands/project.d.ts +15 -186
- package/dist/commands/project.js +93 -921
- package/dist/commands/result.d.ts +10 -0
- package/dist/commands/result.js +215 -0
- package/dist/commands/schedule.d.ts +0 -29
- package/dist/commands/schedule.js +47 -97
- package/dist/commands/test.d.ts +315 -1824
- package/dist/commands/test.js +1962 -13733
- package/dist/commands/testlist.d.ts +128 -5
- package/dist/commands/testlist.js +269 -329
- package/dist/commands/tunnel.d.ts +2 -2
- package/dist/commands/tunnel.js +43 -41
- package/dist/commands/usage.d.ts +12 -45
- package/dist/commands/usage.js +51 -131
- package/dist/index.js +189 -108
- package/dist/lib/agent-detect.js +9 -5
- package/dist/lib/agent-targets.d.ts +21 -2
- package/dist/lib/agent-targets.js +88 -11
- package/dist/lib/args.d.ts +13 -0
- package/dist/lib/args.js +49 -0
- package/dist/lib/basic-auth.d.ts +3 -0
- package/dist/lib/basic-auth.js +15 -0
- package/dist/lib/billing-refusal.js +4 -3
- package/dist/lib/ci-linkage.d.ts +4 -82
- package/dist/lib/ci-linkage.js +4 -157
- package/dist/lib/ci-run.js +1 -1
- package/dist/lib/client-factory.d.ts +10 -2
- package/dist/lib/client-factory.js +38 -26
- package/dist/lib/commit-signal.d.ts +65 -0
- package/dist/lib/commit-signal.js +305 -0
- package/dist/lib/concurrency-limiter.d.ts +6 -0
- package/dist/lib/concurrency-limiter.js +29 -0
- package/dist/lib/config.js +10 -5
- package/dist/lib/conflict-reason.d.ts +31 -4
- package/dist/lib/conflict-reason.js +38 -4
- package/dist/lib/conversation/answers.d.ts +9 -0
- package/dist/lib/conversation/answers.js +49 -0
- package/dist/lib/conversation/api.d.ts +71 -0
- package/dist/lib/conversation/api.js +150 -0
- package/dist/lib/conversation/change.d.ts +31 -0
- package/dist/lib/conversation/change.js +124 -0
- package/dist/lib/conversation/context.d.ts +19 -0
- package/dist/lib/conversation/context.js +70 -0
- package/dist/lib/conversation/environment.d.ts +15 -0
- package/dist/lib/conversation/environment.js +33 -0
- package/dist/lib/conversation/follow.d.ts +24 -0
- package/dist/lib/conversation/follow.js +42 -0
- package/dist/lib/conversation/render.d.ts +33 -0
- package/dist/lib/conversation/render.js +315 -0
- package/dist/lib/conversation/title.d.ts +2 -0
- package/dist/lib/conversation/title.js +18 -0
- package/dist/lib/conversation/types.d.ts +156 -0
- package/dist/lib/conversation/types.js +6 -0
- package/dist/lib/credentials.js +67 -11
- package/dist/lib/cron.d.ts +1 -1
- package/dist/lib/cron.js +2 -2
- package/dist/lib/dispatch-stop.d.ts +20 -0
- package/dist/lib/dispatch-stop.js +30 -0
- package/dist/lib/download.d.ts +71 -0
- package/dist/lib/download.js +274 -0
- package/dist/lib/dry-run/fetch.d.ts +10 -0
- package/dist/lib/dry-run/fetch.js +20 -0
- package/dist/lib/dry-run/samples.d.ts +6 -34
- package/dist/lib/dry-run/samples.js +389 -751
- package/dist/lib/environment-tunnel.d.ts +16 -26
- package/dist/lib/environment-tunnel.js +161 -157
- package/dist/lib/errors.d.ts +20 -4
- package/dist/lib/errors.js +36 -16
- package/dist/lib/facade.d.ts +7 -29
- package/dist/lib/facade.js +7 -36
- package/dist/lib/failing-fe-resolver.d.ts +13 -58
- package/dist/lib/failing-fe-resolver.js +47 -132
- package/dist/lib/first-suite-hint.d.ts +16 -22
- package/dist/lib/first-suite-hint.js +38 -47
- package/dist/lib/gh-output.d.ts +76 -21
- package/dist/lib/gh-output.js +171 -90
- package/dist/lib/git-utils.d.ts +56 -0
- package/dist/lib/git-utils.js +212 -0
- package/dist/lib/github-context.d.ts +2 -0
- package/dist/lib/github-context.js +40 -8
- package/dist/lib/history-retention.d.ts +6 -2
- package/dist/lib/history-retention.js +10 -7
- package/dist/lib/http.d.ts +58 -134
- package/dist/lib/http.js +352 -271
- package/dist/lib/interrupt.d.ts +14 -8
- package/dist/lib/interrupt.js +28 -10
- package/dist/lib/junit-report.d.ts +60 -4
- package/dist/lib/junit-report.js +209 -32
- package/dist/lib/local-target.d.ts +3 -3
- package/dist/lib/local-target.js +3 -3
- package/dist/lib/output.d.ts +0 -29
- package/dist/lib/output.js +10 -33
- package/dist/lib/pagination.d.ts +2 -5
- package/dist/lib/pagination.js +2 -5
- package/dist/lib/presigned-url.d.ts +22 -0
- package/dist/lib/presigned-url.js +90 -0
- package/dist/lib/prompt.js +36 -2
- package/dist/lib/proxy.js +2 -1
- package/dist/lib/redact.d.ts +2 -2
- package/dist/lib/redact.js +3 -4
- package/dist/lib/removed-commands.d.ts +18 -0
- package/dist/lib/removed-commands.js +154 -0
- package/dist/lib/render-error.d.ts +31 -6
- package/dist/lib/render-error.js +88 -25
- package/dist/lib/response-schemas.d.ts +38 -30
- package/dist/lib/response-schemas.js +210 -207
- package/dist/lib/result/api.d.ts +24 -0
- package/dist/lib/result/api.js +28 -0
- package/dist/lib/result/evidence.d.ts +71 -0
- package/dist/lib/result/evidence.js +420 -0
- package/dist/lib/result/render.d.ts +20 -0
- package/dist/lib/result/render.js +194 -0
- package/dist/lib/result/types.d.ts +122 -0
- package/dist/lib/result/types.js +19 -0
- package/dist/lib/run-output.d.ts +275 -0
- package/dist/lib/run-output.js +227 -0
- package/dist/lib/run-render.d.ts +101 -0
- package/dist/lib/run-render.js +183 -0
- package/dist/lib/run-wait.d.ts +192 -0
- package/dist/lib/run-wait.js +452 -0
- package/dist/lib/runs.types.d.ts +134 -367
- package/dist/lib/runs.types.js +0 -14
- package/dist/lib/secret-file.d.ts +1 -1
- package/dist/lib/secret-file.js +11 -2
- package/dist/lib/skill-nudge.d.ts +7 -27
- package/dist/lib/skill-nudge.js +9 -37
- package/dist/lib/target-path.d.ts +15 -0
- package/dist/lib/target-path.js +35 -0
- package/dist/lib/target-url-advisory.d.ts +19 -0
- package/dist/lib/target-url-advisory.js +31 -0
- package/dist/lib/target-url-preflight.d.ts +9 -0
- package/dist/lib/target-url-preflight.js +214 -106
- package/dist/lib/target-url.d.ts +1 -1
- package/dist/lib/target-url.js +6 -16
- package/dist/lib/telemetry.d.ts +32 -12
- package/dist/lib/telemetry.js +39 -8
- package/dist/lib/terminal-text.d.ts +41 -0
- package/dist/lib/terminal-text.js +127 -0
- package/dist/lib/testlist.types.d.ts +16 -8
- package/dist/lib/testlist.types.js +1 -1
- package/dist/lib/text-equality.d.ts +2 -0
- package/dist/lib/text-equality.js +5 -0
- package/dist/lib/text-file.d.ts +16 -0
- package/dist/lib/text-file.js +41 -0
- package/dist/lib/text-table.d.ts +46 -0
- package/dist/lib/text-table.js +72 -4
- package/dist/lib/ticker.d.ts +9 -2
- package/dist/lib/ticker.js +16 -3
- package/dist/lib/transport-failure.d.ts +22 -0
- package/dist/lib/transport-failure.js +126 -0
- package/dist/lib/tunnel-session.d.ts +7 -1
- package/dist/lib/tunnel-session.js +22 -9
- package/dist/lib/update-check.js +3 -2
- package/dist/lib/url-template.d.ts +43 -0
- package/dist/lib/url-template.js +151 -0
- package/dist/lib/validate.d.ts +0 -64
- package/dist/lib/validate.js +2 -131
- package/dist/lib/version-notice.js +4 -3
- package/dist/lib/wait-exit.d.ts +37 -2
- package/dist/lib/wait-exit.js +88 -30
- package/dist/lib/workspace-status.js +10 -2
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -4
- package/skills/testsprite-ci.skill.md +48 -18
- package/skills/testsprite-onboard.skill.md +66 -151
- package/skills/testsprite-verify.codex.md +54 -56
- package/skills/testsprite-verify.skill.md +194 -358
- package/dist/lib/browser.d.ts +0 -6
- package/dist/lib/browser.js +0 -54
- package/dist/lib/bundle.d.ts +0 -234
- package/dist/lib/bundle.js +0 -781
- package/dist/lib/deprecate.d.ts +0 -10
- package/dist/lib/deprecate.js +0 -13
- package/dist/lib/flaky.d.ts +0 -91
- package/dist/lib/flaky.js +0 -71
- package/dist/lib/plan-poll.d.ts +0 -171
- package/dist/lib/plan-poll.js +0 -441
- package/dist/lib/plans.types.d.ts +0 -130
- package/dist/lib/plans.types.js +0 -31
- package/dist/lib/poll.d.ts +0 -100
- package/dist/lib/poll.js +0 -290
- package/dist/lib/rate-throttle.d.ts +0 -49
- package/dist/lib/rate-throttle.js +0 -75
- package/dist/lib/run-progress.d.ts +0 -41
- package/dist/lib/run-progress.js +0 -56
- package/dist/lib/v3-advisory.d.ts +0 -55
- package/dist/lib/v3-advisory.js +0 -74
- package/schemas/plan.schema.json +0 -61
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export declare const SAMPLE_RUN_ID = "run_abc";
|
|
2
1
|
export declare const SAMPLE_DRY_RUN_REQUEST_ID = "req_dry-run";
|
|
3
2
|
/**
|
|
4
3
|
* Canned JUnit XML for batch `--wait --report junit --dry-run`. Mirrors the
|
|
@@ -8,16 +7,10 @@ export declare function sampleJUnitReportXml(projectId?: string, reportSuiteName
|
|
|
8
7
|
/**
|
|
9
8
|
* Dry-run sample lookup keyed by OpenAPI operationId. Order matters in
|
|
10
9
|
* {@link findSample}: more specific patterns must precede their generic
|
|
11
|
-
* siblings (e.g. `/
|
|
10
|
+
* siblings (e.g. `/projects/{id}/env` before `/projects/{id}`).
|
|
12
11
|
*/
|
|
13
12
|
/**
|
|
14
|
-
* HTTP methods accepted by the dry-run registry.
|
|
15
|
-
* read surface; POST landed with M3.2 piece-2 (`POST /api/cli/v1/tests`)
|
|
16
|
-
* and gained `/tests/batch` with M3.2 piece-5; PUT + DELETE landed with
|
|
17
|
-
* M3.2 piece-3 (`PUT/DELETE /api/cli/v1/tests/{id}`); piece-4 added
|
|
18
|
-
* `PUT /api/cli/v1/tests/{id}/code`; piece-6 added
|
|
19
|
-
* `PUT /api/cli/v1/tests/{id}/plan-steps`. The list grows as new
|
|
20
|
-
* mutation routes ship.
|
|
13
|
+
* HTTP methods accepted by the dry-run registry.
|
|
21
14
|
*/
|
|
22
15
|
export type DryRunMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
|
|
23
16
|
export interface DryRunSampleEntry {
|
|
@@ -33,41 +26,20 @@ export interface DryRunSampleEntry {
|
|
|
33
26
|
* receives the parsed request body so the sample can echo back the
|
|
34
27
|
* user's actual field values instead of a static canned placeholder.
|
|
35
28
|
* Simple read-only endpoints use a zero-arity factory that ignores the
|
|
36
|
-
* argument.
|
|
29
|
+
* argument. A read whose answer depends on its query (`GET /results`)
|
|
30
|
+
* receives the query too; the query never takes part in matching.
|
|
37
31
|
*/
|
|
38
|
-
body: (requestBody?: unknown) => unknown;
|
|
32
|
+
body: (requestBody?: unknown, query?: URLSearchParams) => unknown;
|
|
39
33
|
}
|
|
40
34
|
/**
|
|
41
35
|
* Build the matcher RegExp for a route template, e.g.
|
|
42
|
-
* `/
|
|
36
|
+
* `/results/{resultId}` → /^\/results\/[^/]+$/. Splits on the
|
|
43
37
|
* `{param}` placeholders first, then regex-escapes every literal segment in
|
|
44
38
|
* between (including any literal backslash) so a route literal containing a
|
|
45
39
|
* regex metacharacter is matched literally instead of being reinterpreted as
|
|
46
40
|
* part of the pattern.
|
|
47
41
|
*/
|
|
48
42
|
declare function buildPathPattern(pathTemplate: string): RegExp;
|
|
49
|
-
/**
|
|
50
|
-
* Resolve a fetch URL to its canned sample. Matches against the path
|
|
51
|
-
* portion only (query string is ignored — auto-pagination's `cursor`
|
|
52
|
-
* query is intentionally a no-op in M2 dry-run; see {@link pageOf}).
|
|
53
|
-
*
|
|
54
|
-
* Returns `undefined` when no pattern matches; the caller (the dry-run
|
|
55
|
-
* fetch impl) surfaces this as a 500 INTERNAL envelope so a missing
|
|
56
|
-
* sample is loud, not silent.
|
|
57
|
-
*
|
|
58
|
-
* `requestBody` is forwarded to input-derived entries (`updateTest`,
|
|
59
|
-
* `putPlanSteps`, `createTestBatch`) so their responses reflect the
|
|
60
|
-
* user's actual flags rather than static canned values.
|
|
61
|
-
*/
|
|
62
|
-
/**
|
|
63
|
-
* Like {@link findSample}, but a missing sample throws instead of returning
|
|
64
|
-
* `undefined`. For dry-run paths that resolve samples DIRECTLY (bypassing the
|
|
65
|
-
* dry-run fetch impl, which has its own loud INTERNAL envelope for this):
|
|
66
|
-
* without the throw, a lost registry entry surfaces as a raw TypeError deep
|
|
67
|
-
* in a renderer (`samples.ts` is a real merge-conflict
|
|
68
|
-
* hotspot, so a silently dropped entry is a live hazard, not a hypothetical).
|
|
69
|
-
*/
|
|
70
|
-
export declare function findSampleOrThrow(method: string, url: string, requestBody?: unknown): DryRunSampleEntry;
|
|
71
43
|
export declare function findSample(method: string, url: string, requestBody?: unknown): DryRunSampleEntry | undefined;
|
|
72
44
|
/** Test-only export so `samples.test.ts` can iterate the catalog. */
|
|
73
45
|
export declare const DRY_RUN_SAMPLE_ENTRIES: ReadonlyArray<DryRunSampleEntry>;
|