@gate-forge/cli 0.4.1 → 0.6.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 +32 -11
- package/dist/args.js +1 -1
- package/dist/args.js.map +1 -1
- package/dist/broker.d.ts.map +1 -1
- package/dist/broker.js +65 -119
- package/dist/broker.js.map +1 -1
- package/dist/candidate-tree.d.ts +36 -0
- package/dist/candidate-tree.d.ts.map +1 -0
- package/dist/candidate-tree.js +321 -0
- package/dist/candidate-tree.js.map +1 -0
- package/dist/cli.d.ts +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +11 -3
- package/dist/cli.js.map +1 -1
- package/dist/commands/adopt.js +2 -2
- package/dist/commands/adopt.js.map +1 -1
- package/dist/commands/check.d.ts.map +1 -1
- package/dist/commands/check.js +9 -3
- package/dist/commands/check.js.map +1 -1
- package/dist/commands/enforcement.d.ts.map +1 -1
- package/dist/commands/enforcement.js +61 -1
- package/dist/commands/enforcement.js.map +1 -1
- package/dist/commands/explain.d.ts.map +1 -1
- package/dist/commands/explain.js +2 -7
- package/dist/commands/explain.js.map +1 -1
- package/dist/commands/init.d.ts +6 -2
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +328 -58
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/next.d.ts +15 -0
- package/dist/commands/next.d.ts.map +1 -0
- package/dist/commands/next.js +337 -0
- package/dist/commands/next.js.map +1 -0
- package/dist/commands/test-gates.d.ts +18 -0
- package/dist/commands/test-gates.d.ts.map +1 -1
- package/dist/commands/test-gates.js +149 -5
- package/dist/commands/test-gates.js.map +1 -1
- package/dist/commands/tests.js +114 -13
- package/dist/commands/tests.js.map +1 -1
- package/dist/evaluate.d.ts +8 -0
- package/dist/evaluate.d.ts.map +1 -1
- package/dist/evaluate.js +19 -10
- package/dist/evaluate.js.map +1 -1
- package/dist/execution.d.ts +20 -0
- package/dist/execution.d.ts.map +1 -1
- package/dist/execution.js +14 -2
- package/dist/execution.js.map +1 -1
- package/dist/input-snapshot.d.ts.map +1 -1
- package/dist/input-snapshot.js +4 -0
- package/dist/input-snapshot.js.map +1 -1
- package/dist/io.d.ts.map +1 -1
- package/dist/io.js.map +1 -1
- package/dist/mapping.d.ts +29 -9
- package/dist/mapping.d.ts.map +1 -1
- package/dist/mapping.js +37 -10
- package/dist/mapping.js.map +1 -1
- package/dist/pipeline.d.ts +14 -4
- package/dist/pipeline.d.ts.map +1 -1
- package/dist/pipeline.js +64 -7
- package/dist/pipeline.js.map +1 -1
- package/dist/receipts.d.ts +8 -0
- package/dist/receipts.d.ts.map +1 -1
- package/dist/receipts.js +4 -0
- package/dist/receipts.js.map +1 -1
- package/dist/repo-scan.d.ts +63 -0
- package/dist/repo-scan.d.ts.map +1 -0
- package/dist/repo-scan.js +272 -0
- package/dist/repo-scan.js.map +1 -0
- package/dist/scope.d.ts.map +1 -1
- package/dist/scope.js +3 -0
- package/dist/scope.js.map +1 -1
- package/dist/state.d.ts.map +1 -1
- package/dist/state.js +2 -7
- package/dist/state.js.map +1 -1
- package/package.json +9 -9
|
@@ -0,0 +1,337 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `gateforge next`: the only agent-facing navigation command — exactly
|
|
3
|
+
* ONE blocking next action, never a dump.
|
|
4
|
+
*
|
|
5
|
+
* Runs the same discover → classify → obligations → evaluate path as
|
|
6
|
+
* `check` (without `--require-e2e`: next is navigation, not the gate),
|
|
7
|
+
* collects blocking entries plus verdicts whose status is blocking, and
|
|
8
|
+
* prints the single highest-ranked item. Exit 0 when clean, 1 when a
|
|
9
|
+
* next action exists, 2 on config/usage errors.
|
|
10
|
+
*/
|
|
11
|
+
import { existsSync } from 'node:fs';
|
|
12
|
+
import { join } from 'node:path';
|
|
13
|
+
import { BLOCKING_VERDICTS, CAUSE_NEXT_ACTIONS, } from '@gate-forge/core';
|
|
14
|
+
import { discoverTestCatalog, findPlaywrightConfig } from '@gate-forge/pack-playwright';
|
|
15
|
+
import { parseArgs } from '../args.js';
|
|
16
|
+
import { resolveAdoptedBaseline } from '../adopted-baseline.js';
|
|
17
|
+
import { UsageError } from '../errors.js';
|
|
18
|
+
import { writeLine } from '../io.js';
|
|
19
|
+
import { evaluateRun } from '../evaluate.js';
|
|
20
|
+
import { gradingClaimsFor, loadOptionalTestMap, mappedCoverageFrom, mappingBlocking, resolveRepositoryMappings, } from '../mapping.js';
|
|
21
|
+
import { collectInputFiles, computeInputSnapshot, diffInputFiles, SnapshotUnavailableError, UnsupportedSnapshotError, } from '../input-snapshot.js';
|
|
22
|
+
import { runPipeline, sourcesByResourceId } from '../pipeline.js';
|
|
23
|
+
import { resolveProvider } from '../providers.js';
|
|
24
|
+
import { computeEvaluationScope, detectStagedWorkingTreeMismatches } from '../scope.js';
|
|
25
|
+
import { httpRoutesView, resolveStateDir } from '../state.js';
|
|
26
|
+
import { loadConfigAt, rejectUnknownFlags, VERIFIER_KEY_ENV } from './common.js';
|
|
27
|
+
export const NEXT_USAGE = 'usage: gateforge next [--changed] [--json]';
|
|
28
|
+
/**
|
|
29
|
+
* Ranks a cause per the plan §2 table: capability gaps first, mapping
|
|
30
|
+
* intent last, everything else blocking after that.
|
|
31
|
+
*/
|
|
32
|
+
function rankCause(cause, kind) {
|
|
33
|
+
switch (cause) {
|
|
34
|
+
case 'VERIFIER_UNSUPPORTED':
|
|
35
|
+
return 1;
|
|
36
|
+
// Complete-behavior setup/declaration problems block before any
|
|
37
|
+
// test-generation advice: an owner document gap is not something a
|
|
38
|
+
// test can fix (plan §5 — rank configuration first).
|
|
39
|
+
case 'ENDPOINT_BEHAVIOR_MISSING':
|
|
40
|
+
case 'BEHAVIOR_REFERENCE_STALE':
|
|
41
|
+
case 'BEHAVIOR_CASE_UNMAPPED':
|
|
42
|
+
case 'BEHAVIOR_CASE_MISSING':
|
|
43
|
+
case 'BEHAVIOR_BINDING_MISMATCH':
|
|
44
|
+
case 'BEHAVIOR_EFFECT_MISMATCH':
|
|
45
|
+
case 'OBSERVATION_SCOPE_INCOMPLETE':
|
|
46
|
+
case 'BEHAVIOR_UNEXPECTED_EFFECT':
|
|
47
|
+
case 'ENFORCEMENT_BOUNDARY_UNVERIFIED':
|
|
48
|
+
return 2;
|
|
49
|
+
case 'CRUD_COVERAGE_MISSING':
|
|
50
|
+
return 3;
|
|
51
|
+
case 'CHANGE_UNMAPPED':
|
|
52
|
+
return 4;
|
|
53
|
+
case 'ENFORCEMENT_UNTRUSTED':
|
|
54
|
+
return 5;
|
|
55
|
+
case 'EVIDENCE_NOT_COLLECTED':
|
|
56
|
+
return 6;
|
|
57
|
+
case 'EVIDENCE_STALE':
|
|
58
|
+
case 'RUN_INCOMPLETE':
|
|
59
|
+
case 'TEST_NOT_EXECUTED':
|
|
60
|
+
case 'TEST_FAILED':
|
|
61
|
+
return 7;
|
|
62
|
+
case 'TEST_MAPPING_MISSING':
|
|
63
|
+
case 'TEST_MAPPING_AMBIGUOUS':
|
|
64
|
+
case 'TEST_MAPPING_STALE':
|
|
65
|
+
case 'TEST_KIND_UNKNOWN':
|
|
66
|
+
return 8;
|
|
67
|
+
default:
|
|
68
|
+
break;
|
|
69
|
+
}
|
|
70
|
+
if (cause === null || cause === undefined) {
|
|
71
|
+
// Unclassified / unresolved / parse findings sort right after
|
|
72
|
+
// capability gaps; a blocking verdict without a cause is still an
|
|
73
|
+
// unsatisfied obligation (missing-evidence rank).
|
|
74
|
+
if (kind === 'unclassified' || kind === 'unresolved' || kind === 'finding')
|
|
75
|
+
return 2;
|
|
76
|
+
if (kind === 'verdict')
|
|
77
|
+
return 6;
|
|
78
|
+
return 9;
|
|
79
|
+
}
|
|
80
|
+
return 9;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Normalizes blocking entries + blocking verdicts into ranked
|
|
84
|
+
* candidates (stable sort by id inside a rank).
|
|
85
|
+
*/
|
|
86
|
+
function rankBlockers(blocking, verdicts) {
|
|
87
|
+
const candidates = [];
|
|
88
|
+
for (const entry of blocking) {
|
|
89
|
+
const cause = entry.cause ?? null;
|
|
90
|
+
candidates.push({
|
|
91
|
+
id: entry.resourceId ?? entry.name ?? 'repo',
|
|
92
|
+
cause: cause ?? 'BLOCKING_FINDING',
|
|
93
|
+
why: entry.detail,
|
|
94
|
+
do: entry.nextAction ??
|
|
95
|
+
(cause !== null ? CAUSE_NEXT_ACTIONS[cause] : 'Run `gateforge check` for the full report and resolve this blocker.'),
|
|
96
|
+
rank: rankCause(cause, entry.kind),
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
for (const verdict of verdicts) {
|
|
100
|
+
if (!BLOCKING_VERDICTS.includes(verdict.verdict))
|
|
101
|
+
continue;
|
|
102
|
+
const cause = verdict.cause ?? null;
|
|
103
|
+
candidates.push({
|
|
104
|
+
id: verdict.obligation.id,
|
|
105
|
+
cause: cause ?? 'EVIDENCE_NOT_COLLECTED',
|
|
106
|
+
why: verdict.reason ?? `obligation '${verdict.obligation.id}' is ${verdict.verdict}`,
|
|
107
|
+
do: verdict.nextAction ??
|
|
108
|
+
(cause !== null ? CAUSE_NEXT_ACTIONS[cause] : CAUSE_NEXT_ACTIONS['EVIDENCE_NOT_COLLECTED']),
|
|
109
|
+
rank: rankCause(cause, 'verdict'),
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
candidates.sort((a, b) => (a.rank !== b.rank ? a.rank - b.rank : a.id < b.id ? -1 : a.id > b.id ? 1 : 0));
|
|
113
|
+
return candidates;
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Runs the `gateforge next` subcommand.
|
|
117
|
+
*
|
|
118
|
+
* Args:
|
|
119
|
+
* io: process context.
|
|
120
|
+
* argv: flags after the subcommand.
|
|
121
|
+
*
|
|
122
|
+
* Returns:
|
|
123
|
+
* number: exit code — 0 clean, 1 a next action exists, 2
|
|
124
|
+
* config/usage.
|
|
125
|
+
*/
|
|
126
|
+
export async function nextCommand(io, argv) {
|
|
127
|
+
const { options } = parseArgs(argv);
|
|
128
|
+
if (options['help'] === true) {
|
|
129
|
+
writeLine(io.stdout, NEXT_USAGE);
|
|
130
|
+
return 0;
|
|
131
|
+
}
|
|
132
|
+
rejectUnknownFlags(options, ['changed', 'json', 'help'], NEXT_USAGE);
|
|
133
|
+
if (!existsSync(join(io.cwd, '.gateforge.yml'))) {
|
|
134
|
+
throw new UsageError('no .gateforge.yml found — run gateforge init first');
|
|
135
|
+
}
|
|
136
|
+
const diffScoped = options['changed'] === true;
|
|
137
|
+
const asJson = options['json'] === true;
|
|
138
|
+
const witnessVerifierKey = io.env[VERIFIER_KEY_ENV];
|
|
139
|
+
const config = loadConfigAt(io.cwd);
|
|
140
|
+
const providerIdentity = diffScoped
|
|
141
|
+
? resolveProvider(config.changed.provider, io.cwd, io.env).provider
|
|
142
|
+
: 'all-files';
|
|
143
|
+
const stateDir = resolveStateDir(io.cwd);
|
|
144
|
+
// Trusted digest: the same pre/post inventory check `check` performs
|
|
145
|
+
// so witnessed records authorize for the current bytes (next never
|
|
146
|
+
// demands a gate receipt — navigation, not the gate).
|
|
147
|
+
let preFiles = null;
|
|
148
|
+
let snapshotUnavailable = false;
|
|
149
|
+
try {
|
|
150
|
+
preFiles = collectInputFiles(io.cwd, config, stateDir);
|
|
151
|
+
}
|
|
152
|
+
catch (error) {
|
|
153
|
+
if (error instanceof SnapshotUnavailableError) {
|
|
154
|
+
snapshotUnavailable = true;
|
|
155
|
+
}
|
|
156
|
+
else if (error instanceof UnsupportedSnapshotError) {
|
|
157
|
+
throw new UsageError(`unsupported input snapshot: ${error.message}`);
|
|
158
|
+
}
|
|
159
|
+
else {
|
|
160
|
+
throw error;
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
const pipeline = await runPipeline({
|
|
164
|
+
cwd: io.cwd,
|
|
165
|
+
env: io.env,
|
|
166
|
+
config,
|
|
167
|
+
provider: providerIdentity,
|
|
168
|
+
stateDir,
|
|
169
|
+
});
|
|
170
|
+
const httpRoutes = httpRoutesView(pipeline.graph);
|
|
171
|
+
let expectedDigest = null;
|
|
172
|
+
let changedInputs = false;
|
|
173
|
+
if (!snapshotUnavailable) {
|
|
174
|
+
try {
|
|
175
|
+
const postFiles = collectInputFiles(io.cwd, config, stateDir);
|
|
176
|
+
if (preFiles !== null && diffInputFiles(preFiles, postFiles).length > 0) {
|
|
177
|
+
changedInputs = true;
|
|
178
|
+
}
|
|
179
|
+
else {
|
|
180
|
+
expectedDigest = computeInputSnapshot({
|
|
181
|
+
cwd: io.cwd,
|
|
182
|
+
config,
|
|
183
|
+
stateDir,
|
|
184
|
+
classifications: pipeline.classificationsView.resources,
|
|
185
|
+
obligations: pipeline.policy.obligations,
|
|
186
|
+
httpRoutes,
|
|
187
|
+
plugins: pipeline.manifest.plugins.map((plugin) => ({
|
|
188
|
+
id: plugin.id,
|
|
189
|
+
version: plugin.version,
|
|
190
|
+
})),
|
|
191
|
+
}).inputDigest;
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
catch (error) {
|
|
195
|
+
if (error instanceof SnapshotUnavailableError) {
|
|
196
|
+
snapshotUnavailable = true;
|
|
197
|
+
}
|
|
198
|
+
else if (error instanceof UnsupportedSnapshotError) {
|
|
199
|
+
throw new UsageError(`unsupported input snapshot: ${error.message}`);
|
|
200
|
+
}
|
|
201
|
+
else {
|
|
202
|
+
throw error;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
// One effective evaluation scope (same contract as check --changed):
|
|
207
|
+
// gate-defining inputs expand to all; strict-mode unmapped files add
|
|
208
|
+
// CHANGE_UNMAPPED blockers; staged/worktree divergence blocks loudly.
|
|
209
|
+
let changedFiles = null;
|
|
210
|
+
let mismatchBlocking = [];
|
|
211
|
+
if (diffScoped) {
|
|
212
|
+
const sidecar = loadOptionalTestMap(io.cwd);
|
|
213
|
+
const runnerConfig = findPlaywrightConfig(io.cwd);
|
|
214
|
+
let testFiles = [];
|
|
215
|
+
if (runnerConfig !== null) {
|
|
216
|
+
try {
|
|
217
|
+
testFiles = (await discoverTestCatalog({ cwd: io.cwd, config })).catalog.entries
|
|
218
|
+
.filter((entry) => entry.runner === 'playwright')
|
|
219
|
+
.map((entry) => entry.file);
|
|
220
|
+
}
|
|
221
|
+
catch {
|
|
222
|
+
testFiles = [];
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
const knownSourceFiles = [
|
|
226
|
+
...new Set(pipeline.graph.resources.flatMap((resource) => resource.id === null ? [] : sourcesByResourceId(pipeline.graph, pipeline.behaviorCatalog).get(resource.id) ?? [])),
|
|
227
|
+
];
|
|
228
|
+
const scopeDecision = computeEvaluationScope({
|
|
229
|
+
config,
|
|
230
|
+
changedFiles: pipeline.changedFiles,
|
|
231
|
+
testFiles,
|
|
232
|
+
runnerConfigs: runnerConfig === null ? [] : [runnerConfig],
|
|
233
|
+
mappingSidecar: sidecar !== null,
|
|
234
|
+
knownSourceFiles,
|
|
235
|
+
strictE2E: config.enforcement?.strictE2E === true,
|
|
236
|
+
});
|
|
237
|
+
changedFiles = scopeDecision.mode === 'all' ? null : scopeDecision.changedFiles;
|
|
238
|
+
const sidecarCoveredFiles = new Set((sidecar?.tests ?? []).map((entry) => entry.selector.file));
|
|
239
|
+
mismatchBlocking = [
|
|
240
|
+
...mismatchBlocking,
|
|
241
|
+
...scopeDecision.unmappedFiles
|
|
242
|
+
.filter((file) => !sidecarCoveredFiles.has(file))
|
|
243
|
+
.map((file) => ({
|
|
244
|
+
kind: 'finding',
|
|
245
|
+
resourceId: null,
|
|
246
|
+
name: file,
|
|
247
|
+
detail: `changed file '${file}' has no safe obligation/journey scope — unknown behavior changes ` +
|
|
248
|
+
'stay visible and blocking until mapped (strict E2E mode)',
|
|
249
|
+
location: { file, line: 1, col: 0 },
|
|
250
|
+
cause: 'CHANGE_UNMAPPED',
|
|
251
|
+
nextAction: CAUSE_NEXT_ACTIONS.CHANGE_UNMAPPED,
|
|
252
|
+
})),
|
|
253
|
+
];
|
|
254
|
+
if (providerIdentity === 'local-staged') {
|
|
255
|
+
const mismatched = detectStagedWorkingTreeMismatches(io.cwd, io.env);
|
|
256
|
+
if (mismatched.length > 0) {
|
|
257
|
+
changedFiles = null;
|
|
258
|
+
mismatchBlocking = [
|
|
259
|
+
...mismatchBlocking,
|
|
260
|
+
...mismatched.map((file) => ({
|
|
261
|
+
kind: 'finding',
|
|
262
|
+
resourceId: null,
|
|
263
|
+
name: null,
|
|
264
|
+
detail: `staged verification cannot certify '${file}': staged (index) bytes differ ` +
|
|
265
|
+
'from working-tree bytes, but discovery reads the working tree — commit or ' +
|
|
266
|
+
'stash the worktree change, or run without --changed to verify the worktree',
|
|
267
|
+
location: { file, line: 1, col: 0 },
|
|
268
|
+
})),
|
|
269
|
+
];
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
let mappingClaims = [];
|
|
274
|
+
let mappingBlockers = [];
|
|
275
|
+
let mappedCoverage = [];
|
|
276
|
+
if (loadOptionalTestMap(io.cwd) !== null) {
|
|
277
|
+
const mapped = await resolveRepositoryMappings({
|
|
278
|
+
cwd: io.cwd,
|
|
279
|
+
config,
|
|
280
|
+
stateDir,
|
|
281
|
+
obligations: pipeline.policy.obligations,
|
|
282
|
+
behaviorCatalog: pipeline.behaviorCatalog,
|
|
283
|
+
});
|
|
284
|
+
mappingClaims = gradingClaimsFor(mapped.resolution, mapped.nativeClaims);
|
|
285
|
+
mappingBlockers = mappingBlocking(mapped.resolution.problems);
|
|
286
|
+
mappedCoverage = mappedCoverageFrom(mapped.resolution, pipeline.policy.obligations, pipeline.graph);
|
|
287
|
+
}
|
|
288
|
+
const evaluated = evaluateRun({
|
|
289
|
+
cwd: io.cwd,
|
|
290
|
+
config,
|
|
291
|
+
graph: pipeline.graph,
|
|
292
|
+
behaviorCatalog: pipeline.behaviorCatalog,
|
|
293
|
+
obligations: pipeline.policy.obligations,
|
|
294
|
+
blocking: [...pipeline.policy.blocking, ...mismatchBlocking, ...mappingBlockers],
|
|
295
|
+
stateDir,
|
|
296
|
+
now: pipeline.now,
|
|
297
|
+
changedFiles,
|
|
298
|
+
mappingClaims,
|
|
299
|
+
mappedCoverage,
|
|
300
|
+
witnessVerifierKey,
|
|
301
|
+
baseline: resolveAdoptedBaseline(io.cwd, config.baselines),
|
|
302
|
+
evidenceContext: {
|
|
303
|
+
expectedInputDigest: expectedDigest,
|
|
304
|
+
snapshotUnavailable,
|
|
305
|
+
requireInvocationId: false,
|
|
306
|
+
changedInputs,
|
|
307
|
+
},
|
|
308
|
+
});
|
|
309
|
+
const candidates = rankBlockers(evaluated.blocking, evaluated.verdicts);
|
|
310
|
+
if (candidates.length === 0) {
|
|
311
|
+
if (asJson) {
|
|
312
|
+
writeLine(io.stdout, JSON.stringify({ next: null, cause: null, why: 'clean', do: null, remainingBlocking: 0 }));
|
|
313
|
+
}
|
|
314
|
+
else {
|
|
315
|
+
writeLine(io.stdout, 'next: none — clean');
|
|
316
|
+
}
|
|
317
|
+
return 0;
|
|
318
|
+
}
|
|
319
|
+
const first = candidates[0];
|
|
320
|
+
if (asJson) {
|
|
321
|
+
writeLine(io.stdout, JSON.stringify({
|
|
322
|
+
next: first.id,
|
|
323
|
+
cause: first.cause,
|
|
324
|
+
why: first.why,
|
|
325
|
+
do: first.do,
|
|
326
|
+
remainingBlocking: candidates.length - 1,
|
|
327
|
+
}));
|
|
328
|
+
}
|
|
329
|
+
else {
|
|
330
|
+
writeLine(io.stdout, `next: ${first.id}`);
|
|
331
|
+
writeLine(io.stdout, `cause: ${first.cause}`);
|
|
332
|
+
writeLine(io.stdout, `why: ${first.why}`);
|
|
333
|
+
writeLine(io.stdout, `do: ${first.do}`);
|
|
334
|
+
}
|
|
335
|
+
return 1;
|
|
336
|
+
}
|
|
337
|
+
//# sourceMappingURL=next.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"next.js","sourceRoot":"","sources":["../../src/commands/next.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,UAAU,EAAE,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,KAAK,CAAC,KAAK,EAAE,CAAC,CAAC;QAC9C,SAAS,CAAC,EAAE,CAAC,MAAM,EAAE,QAAQ,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC;QAC1C,SAAS,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC;IAC1C,CAAC;IACD,OAAO,CAAC,CAAC;AACX,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type BehaviorCatalog, type ObligationVerdict } from '@gate-forge/core';
|
|
1
2
|
import type { Io } from '../io.js';
|
|
2
3
|
export declare const TEST_GATES_USAGE: string;
|
|
3
4
|
/**
|
|
@@ -31,4 +32,21 @@ export declare function testGatesCommand(io: Io, argv: readonly string[]): Promi
|
|
|
31
32
|
* @throws UsageError on non-integer, out-of-range, or repeated values.
|
|
32
33
|
*/
|
|
33
34
|
export declare function parseRunTimeoutMin(raw: string | undefined): number | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* Computes the receipt's executed-case digest from only authenticated,
|
|
37
|
+
* schema-valid behavior.case records that the evaluator used for a
|
|
38
|
+
* satisfied obligation verdict. Unreferenced, malformed, claimed, or
|
|
39
|
+
* mismatched records are ignored.
|
|
40
|
+
*
|
|
41
|
+
* Args:
|
|
42
|
+
* stateDir: run-state directory containing records.json.
|
|
43
|
+
* runId: authenticated run identity.
|
|
44
|
+
* behaviorCatalog: trusted compiled behavior catalog, or null.
|
|
45
|
+
* verdicts: final evaluated obligation verdicts.
|
|
46
|
+
*
|
|
47
|
+
* Returns:
|
|
48
|
+
* string: canonical executed-case digest, empty when no catalog cases
|
|
49
|
+
* contributed.
|
|
50
|
+
*/
|
|
51
|
+
export declare function executedBehaviorCaseDigest(stateDir: string, runId: string, behaviorCatalog: BehaviorCatalog | null, verdicts: readonly ObligationVerdict[]): string;
|
|
34
52
|
//# sourceMappingURL=test-gates.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"test-gates.d.ts","sourceRoot":"","sources":["../../src/commands/test-gates.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"test-gates.d.ts","sourceRoot":"","sources":["../../src/commands/test-gates.ts"],"names":[],"mappings":"AA2DA,OAAO,EAqBL,KAAK,eAAe,EAIpB,KAAK,iBAAiB,EAKvB,MAAM,kBAAkB,CAAC;AAe1B,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,UAAU,CAAC;AAgDnC,eAAO,MAAM,gBAAgB,QAOgF,CAAC;AAE9G;;;;;;;;;;;GAWG;AACH,wBAAsB,gBAAgB,CAAC,EAAE,EAAE,EAAE,EAAE,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAgDvF;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,CAU9E;AAgwCD;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,0BAA0B,CACxC,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,EACb,eAAe,EAAE,eAAe,GAAG,IAAI,EACvC,QAAQ,EAAE,SAAS,iBAAiB,EAAE,GACrC,MAAM,CAgDR"}
|