@nokout/big-dill-core 0.0.1
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/LICENSE +21 -0
- package/README.md +202 -0
- package/dist/completion/complete.d.ts +40 -0
- package/dist/completion/complete.d.ts.map +1 -0
- package/dist/completion/complete.js +134 -0
- package/dist/completion/complete.js.map +1 -0
- package/dist/format/tables.d.ts +7 -0
- package/dist/format/tables.d.ts.map +1 -0
- package/dist/format/tables.js +87 -0
- package/dist/format/tables.js.map +1 -0
- package/dist/gherkin/parser.d.ts +28 -0
- package/dist/gherkin/parser.d.ts.map +1 -0
- package/dist/gherkin/parser.js +44 -0
- package/dist/gherkin/parser.js.map +1 -0
- package/dist/index.d.ts +25 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +92 -0
- package/dist/index.js.map +1 -0
- package/dist/ipc/server.d.ts +13 -0
- package/dist/ipc/server.d.ts.map +1 -0
- package/dist/ipc/server.js +106 -0
- package/dist/ipc/server.js.map +1 -0
- package/dist/lint/rules.d.ts +46 -0
- package/dist/lint/rules.d.ts.map +1 -0
- package/dist/lint/rules.js +387 -0
- package/dist/lint/rules.js.map +1 -0
- package/dist/protocol/types.d.ts +97 -0
- package/dist/protocol/types.d.ts.map +1 -0
- package/dist/protocol/types.js +5 -0
- package/dist/protocol/types.js.map +1 -0
- package/dist/pytest/runner.d.ts +29 -0
- package/dist/pytest/runner.d.ts.map +1 -0
- package/dist/pytest/runner.js +225 -0
- package/dist/pytest/runner.js.map +1 -0
- package/dist/results/outcomes.d.ts +36 -0
- package/dist/results/outcomes.d.ts.map +1 -0
- package/dist/results/outcomes.js +69 -0
- package/dist/results/outcomes.js.map +1 -0
- package/dist/steps/browser.d.ts +42 -0
- package/dist/steps/browser.d.ts.map +1 -0
- package/dist/steps/browser.js +110 -0
- package/dist/steps/browser.js.map +1 -0
- package/dist/steps/documentation.d.ts +10 -0
- package/dist/steps/documentation.d.ts.map +1 -0
- package/dist/steps/documentation.js +39 -0
- package/dist/steps/documentation.js.map +1 -0
- package/dist/steps/references.d.ts +10 -0
- package/dist/steps/references.d.ts.map +1 -0
- package/dist/steps/references.js +34 -0
- package/dist/steps/references.js.map +1 -0
- package/dist/steps/stepCache.d.ts +50 -0
- package/dist/steps/stepCache.d.ts.map +1 -0
- package/dist/steps/stepCache.js +149 -0
- package/dist/steps/stepCache.js.map +1 -0
- package/dist/steps/stubs.d.ts +10 -0
- package/dist/steps/stubs.d.ts.map +1 -0
- package/dist/steps/stubs.js +46 -0
- package/dist/steps/stubs.js.map +1 -0
- package/dist/steps/unimplemented.d.ts +10 -0
- package/dist/steps/unimplemented.d.ts.map +1 -0
- package/dist/steps/unimplemented.js +26 -0
- package/dist/steps/unimplemented.js.map +1 -0
- package/dist/symbols/outline.d.ts +13 -0
- package/dist/symbols/outline.d.ts.map +1 -0
- package/dist/symbols/outline.js +38 -0
- package/dist/symbols/outline.js.map +1 -0
- package/dist/tokens/semanticTokens.d.ts +13 -0
- package/dist/tokens/semanticTokens.d.ts.map +1 -0
- package/dist/tokens/semanticTokens.js +77 -0
- package/dist/tokens/semanticTokens.js.map +1 -0
- package/dist/tree/builder.d.ts +40 -0
- package/dist/tree/builder.d.ts.map +1 -0
- package/dist/tree/builder.js +178 -0
- package/dist/tree/builder.js.map +1 -0
- package/package.json +58 -0
- package/src/completion/complete.ts +165 -0
- package/src/format/tables.ts +108 -0
- package/src/gherkin/parser.ts +69 -0
- package/src/index.ts +136 -0
- package/src/ipc/server.ts +84 -0
- package/src/lint/rules.ts +425 -0
- package/src/protocol/types.ts +114 -0
- package/src/pytest/runner.ts +249 -0
- package/src/results/outcomes.ts +102 -0
- package/src/steps/browser.ts +105 -0
- package/src/steps/documentation.ts +43 -0
- package/src/steps/references.ts +33 -0
- package/src/steps/stepCache.ts +168 -0
- package/src/steps/stubs.ts +48 -0
- package/src/steps/unimplemented.ts +31 -0
- package/src/symbols/outline.ts +52 -0
- package/src/tokens/semanticTokens.ts +98 -0
- package/src/tree/builder.ts +187 -0
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright (c) 2026 Nigel O'Keefe. All rights reserved.
|
|
3
|
+
// Licensed under the MIT License.
|
|
4
|
+
//
|
|
5
|
+
// Spawns pytest and collects discovery, execution, and lint payloads over the
|
|
6
|
+
// named-pipe IPC channel.
|
|
7
|
+
//
|
|
8
|
+
// Nothing here knows about an editor. Everything a host would otherwise read
|
|
9
|
+
// from editor state — the working directory, the interpreter, extra arguments,
|
|
10
|
+
// where the Python bridge lives, where log output goes, and how cancellation is
|
|
11
|
+
// signalled — arrives as plain options.
|
|
12
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
15
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
16
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
17
|
+
}
|
|
18
|
+
Object.defineProperty(o, k2, desc);
|
|
19
|
+
}) : (function(o, m, k, k2) {
|
|
20
|
+
if (k2 === undefined) k2 = k;
|
|
21
|
+
o[k2] = m[k];
|
|
22
|
+
}));
|
|
23
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
24
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
25
|
+
}) : function(o, v) {
|
|
26
|
+
o["default"] = v;
|
|
27
|
+
});
|
|
28
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
29
|
+
var ownKeys = function(o) {
|
|
30
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
31
|
+
var ar = [];
|
|
32
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
33
|
+
return ar;
|
|
34
|
+
};
|
|
35
|
+
return ownKeys(o);
|
|
36
|
+
};
|
|
37
|
+
return function (mod) {
|
|
38
|
+
if (mod && mod.__esModule) return mod;
|
|
39
|
+
var result = {};
|
|
40
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
41
|
+
__setModuleDefault(result, mod);
|
|
42
|
+
return result;
|
|
43
|
+
};
|
|
44
|
+
})();
|
|
45
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
+
exports.discoverTests = discoverTests;
|
|
47
|
+
exports.runTests = runTests;
|
|
48
|
+
exports.runBddLint = runBddLint;
|
|
49
|
+
const cp = __importStar(require("child_process"));
|
|
50
|
+
const fs = __importStar(require("fs"));
|
|
51
|
+
const os = __importStar(require("os"));
|
|
52
|
+
const path = __importStar(require("path"));
|
|
53
|
+
const server_1 = require("../ipc/server");
|
|
54
|
+
/**
|
|
55
|
+
* Test ids are passed to the runner in a file rather than on the command line:
|
|
56
|
+
* Windows caps a command line at roughly 32,000 characters, and a few hundred
|
|
57
|
+
* scenarios exceeds it with an opaque OS error.
|
|
58
|
+
*/
|
|
59
|
+
const TEST_IDS_ENV = 'BIG_DILL_TEST_IDS';
|
|
60
|
+
/**
|
|
61
|
+
* Wire an AbortSignal to a running subprocess.
|
|
62
|
+
*
|
|
63
|
+
* Handles the already-aborted case too: a signal that fired before the process
|
|
64
|
+
* started would otherwise never deliver an 'abort' event, leaving the run
|
|
65
|
+
* unkillable.
|
|
66
|
+
*/
|
|
67
|
+
function onAbort(signal, handler) {
|
|
68
|
+
if (!signal)
|
|
69
|
+
return;
|
|
70
|
+
if (signal.aborted) {
|
|
71
|
+
handler();
|
|
72
|
+
return;
|
|
73
|
+
}
|
|
74
|
+
signal.addEventListener('abort', handler, { once: true });
|
|
75
|
+
}
|
|
76
|
+
async function discoverTests(opts) {
|
|
77
|
+
const { cwd, interpreterPath, pytestArgs = [], log, signal } = opts;
|
|
78
|
+
const ipc = await (0, server_1.createIpcServer)();
|
|
79
|
+
const env = {
|
|
80
|
+
...process.env,
|
|
81
|
+
TEST_RUN_PIPE: ipc.pipeName,
|
|
82
|
+
};
|
|
83
|
+
const args = [
|
|
84
|
+
'-m', 'pytest',
|
|
85
|
+
'--collect-only',
|
|
86
|
+
'-q',
|
|
87
|
+
'--rootdir', cwd,
|
|
88
|
+
'--import-mode=importlib',
|
|
89
|
+
...pytestArgs,
|
|
90
|
+
];
|
|
91
|
+
let discoveryPayload = null;
|
|
92
|
+
const stepDefinitions = [];
|
|
93
|
+
return new Promise((resolve, reject) => {
|
|
94
|
+
ipc.onMessage((data) => {
|
|
95
|
+
const payload = data;
|
|
96
|
+
if (payload['type'] === 'stepDefinitions') {
|
|
97
|
+
const p = payload;
|
|
98
|
+
stepDefinitions.push(...p.stepDefinitions);
|
|
99
|
+
}
|
|
100
|
+
else if ('cwd' in payload) {
|
|
101
|
+
discoveryPayload = payload;
|
|
102
|
+
}
|
|
103
|
+
});
|
|
104
|
+
const proc = cp.spawn(interpreterPath, args, { cwd, env });
|
|
105
|
+
const stderr = [];
|
|
106
|
+
proc.stderr.on('data', (chunk) => {
|
|
107
|
+
const text = chunk.toString();
|
|
108
|
+
stderr.push(text);
|
|
109
|
+
log?.(text);
|
|
110
|
+
});
|
|
111
|
+
onAbort(signal, () => {
|
|
112
|
+
proc.kill();
|
|
113
|
+
ipc.dispose();
|
|
114
|
+
reject(new Error('Discovery cancelled'));
|
|
115
|
+
});
|
|
116
|
+
proc.on('close', (code) => {
|
|
117
|
+
ipc.dispose();
|
|
118
|
+
const discovery = discoveryPayload ?? {
|
|
119
|
+
cwd,
|
|
120
|
+
status: 'error',
|
|
121
|
+
error: code !== 0 ? stderr : [],
|
|
122
|
+
};
|
|
123
|
+
resolve({ discovery, stepDefinitions });
|
|
124
|
+
});
|
|
125
|
+
proc.on('error', (err) => {
|
|
126
|
+
ipc.dispose();
|
|
127
|
+
reject(err);
|
|
128
|
+
});
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
async function runTests(opts) {
|
|
132
|
+
const { cwd, interpreterPath, pytestArgs = [], log, signal, testIds } = opts;
|
|
133
|
+
const ipc = await (0, server_1.createIpcServer)();
|
|
134
|
+
// mkdtempSync atomically creates a directory with a random suffix and 0700
|
|
135
|
+
// permissions, so the path cannot be predicted or pre-created by another user
|
|
136
|
+
// on a shared machine — unlike a name derived from a timestamp, where a
|
|
137
|
+
// symlink planted at the predicted path turns this into an arbitrary write.
|
|
138
|
+
const tmpDir = fs.mkdtempSync(path.join(os.tmpdir(), 'big-dill-'));
|
|
139
|
+
const testIdsFile = path.join(tmpDir, 'test-ids.txt');
|
|
140
|
+
fs.writeFileSync(testIdsFile, testIds.join('\n'), 'utf-8');
|
|
141
|
+
// Remove the whole directory, from every exit path including cancellation.
|
|
142
|
+
const cleanup = () => {
|
|
143
|
+
try {
|
|
144
|
+
fs.rmSync(tmpDir, { recursive: true, force: true });
|
|
145
|
+
}
|
|
146
|
+
catch { /* ignore */ }
|
|
147
|
+
};
|
|
148
|
+
const env = {
|
|
149
|
+
...process.env,
|
|
150
|
+
TEST_RUN_PIPE: ipc.pipeName,
|
|
151
|
+
[TEST_IDS_ENV]: testIdsFile,
|
|
152
|
+
};
|
|
153
|
+
// Deliberately no --import-mode here: discovery passes importlib and execution
|
|
154
|
+
// never has. Node ids must match between the two or results attach to nothing,
|
|
155
|
+
// and import mode is exactly what shifts them.
|
|
156
|
+
const args = ['-m', 'pytest_big_dill', '--rootdir', cwd, ...pytestArgs];
|
|
157
|
+
const payloads = [];
|
|
158
|
+
return new Promise((resolve, reject) => {
|
|
159
|
+
ipc.onMessage((data) => {
|
|
160
|
+
// Coverage payloads carry a 'coverage' key; they are not results.
|
|
161
|
+
if (!('coverage' in data)) {
|
|
162
|
+
payloads.push(data);
|
|
163
|
+
}
|
|
164
|
+
});
|
|
165
|
+
const proc = cp.spawn(interpreterPath, args, { cwd, env });
|
|
166
|
+
proc.stderr.on('data', (chunk) => log?.(chunk.toString()));
|
|
167
|
+
onAbort(signal, () => {
|
|
168
|
+
proc.kill();
|
|
169
|
+
ipc.dispose();
|
|
170
|
+
cleanup();
|
|
171
|
+
reject(new Error('Test run cancelled'));
|
|
172
|
+
});
|
|
173
|
+
proc.on('close', () => {
|
|
174
|
+
ipc.dispose();
|
|
175
|
+
cleanup();
|
|
176
|
+
resolve(payloads);
|
|
177
|
+
});
|
|
178
|
+
proc.on('error', (err) => {
|
|
179
|
+
ipc.dispose();
|
|
180
|
+
cleanup();
|
|
181
|
+
reject(err);
|
|
182
|
+
});
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
async function runBddLint(opts) {
|
|
186
|
+
const { cwd, interpreterPath, pytestArgs = [], log, signal, featureFilePath } = opts;
|
|
187
|
+
const ipc = await (0, server_1.createIpcServer)();
|
|
188
|
+
const env = {
|
|
189
|
+
...process.env,
|
|
190
|
+
TEST_RUN_PIPE: ipc.pipeName,
|
|
191
|
+
};
|
|
192
|
+
const args = [
|
|
193
|
+
'-m', 'pytest',
|
|
194
|
+
'--bdd-lint', featureFilePath,
|
|
195
|
+
'--rootdir', cwd,
|
|
196
|
+
'--import-mode=importlib',
|
|
197
|
+
...pytestArgs,
|
|
198
|
+
];
|
|
199
|
+
const entries = [];
|
|
200
|
+
return new Promise((resolve, reject) => {
|
|
201
|
+
ipc.onMessage((data) => {
|
|
202
|
+
const payload = data;
|
|
203
|
+
if (payload['type'] === 'lintDiagnostics') {
|
|
204
|
+
const p = payload;
|
|
205
|
+
entries.push(...p.diagnostics);
|
|
206
|
+
}
|
|
207
|
+
});
|
|
208
|
+
const proc = cp.spawn(interpreterPath, args, { cwd, env });
|
|
209
|
+
proc.stderr.on('data', (chunk) => log?.(chunk.toString()));
|
|
210
|
+
onAbort(signal, () => {
|
|
211
|
+
proc.kill();
|
|
212
|
+
ipc.dispose();
|
|
213
|
+
reject(new Error('Lint cancelled'));
|
|
214
|
+
});
|
|
215
|
+
proc.on('close', () => {
|
|
216
|
+
ipc.dispose();
|
|
217
|
+
resolve(entries);
|
|
218
|
+
});
|
|
219
|
+
proc.on('error', (err) => {
|
|
220
|
+
ipc.dispose();
|
|
221
|
+
reject(err);
|
|
222
|
+
});
|
|
223
|
+
});
|
|
224
|
+
}
|
|
225
|
+
//# sourceMappingURL=runner.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runner.js","sourceRoot":"","sources":["../../src/pytest/runner.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,kCAAkC;AAClC,EAAE;AACF,8EAA8E;AAC9E,0BAA0B;AAC1B,EAAE;AACF,6EAA6E;AAC7E,+EAA+E;AAC/E,gFAAgF;AAChF,wCAAwC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6DxC,sCA8DC;AAED,4BA8DC;AAED,gCAkDC;AA7OD,kDAAoC;AACpC,uCAAyB;AACzB,uCAAyB;AACzB,2CAA6B;AAC7B,0CAAgD;AAgChD;;;;GAIG;AACH,MAAM,YAAY,GAAG,mBAAmB,CAAC;AAEzC;;;;;;GAMG;AACH,SAAS,OAAO,CAAC,MAA+B,EAAE,OAAmB;IACjE,IAAI,CAAC,MAAM;QAAE,OAAO;IACpB,IAAI,MAAM,CAAC,OAAO,EAAE,CAAC;QACjB,OAAO,EAAE,CAAC;QACV,OAAO;IACX,CAAC;IACD,MAAM,CAAC,gBAAgB,CAAC,OAAO,EAAE,OAAO,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;AAC9D,CAAC;AAEM,KAAK,UAAU,aAAa,CAAC,IAAmB;IACnD,MAAM,EAAE,GAAG,EAAE,eAAe,EAAE,UAAU,GAAG,EAAE,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IACpE,MAAM,GAAG,GAAG,MAAM,IAAA,wBAAe,GAAE,CAAC;IAEpC,MAAM,GAAG,GAAsB;QAC3B,GAAG,OAAO,CAAC,GAAG;QACd,aAAa,EAAE,GAAG,CAAC,QAAQ;KAC9B,CAAC;IAEF,MAAM,IA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AO,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,WAAW,CAAC,CAAC;YACnC,CAAC;QACL,CAAC,CAAC,CAAC;QAEH,MAAM,IAAI,GAAG,EAAE,CAAC,KAAK,CAAC,eAAe,EAAE,IAAI,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,CAAC;QAE3D,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;QAE3D,OAAO,CAAC,MAAM,EAAE,GAAG,EAAE;YACjB,IAAI,CAAC,IAAI,EAAE,CAAC;YACZ,GAAG,CAAC,OAAO,EAAE,CAAC;YACd,MAAM,CAAC,IAAI,KAAK,CAAC,gBAAgB,CAAC,CAAC,CAAC;QACxC,CAAC,CAAC,CAAC;QAEH,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;YAClB,GAAG,CAAC,OAAO,EAAE,CAAC;YACd,OAAO,CAAC,OAAO,CAAC,CAAC;QACrB,CAAC,CAAC,CAAC;QAEH,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,CAAC,GAAG,EAAE,EAAE;YACrB,GAAG,CAAC,OAAO,EAAE,CAAC;YACd,MAAM,CAAC,GAAG,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;IACP,CAAC,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { ExecutionTestPayload } from '../protocol/types';
|
|
2
|
+
/**
|
|
3
|
+
* 'passed', 'failed', 'errored' and 'skipped' are terminal. 'enqueued' is
|
|
4
|
+
* transient: it shows a pending indicator during a run, but is not stored as a
|
|
5
|
+
* result, so afterwards the item reads as "not run" — visually the same as
|
|
6
|
+
* skipped. Use 'skipped' to mean "deliberately did not run this time".
|
|
7
|
+
*/
|
|
8
|
+
export type RunState = 'passed' | 'failed' | 'errored' | 'skipped' | 'enqueued';
|
|
9
|
+
/** Marker a host may prepend to an item awaiting a result. */
|
|
10
|
+
export declare const WAITING_PREFIX = "\u23F3 ";
|
|
11
|
+
export interface OutcomeDecision {
|
|
12
|
+
/** pytest run id; the host maps this to its own item. */
|
|
13
|
+
runId: string;
|
|
14
|
+
state: RunState;
|
|
15
|
+
/** Attached by the host for failed/errored states. */
|
|
16
|
+
message?: string;
|
|
17
|
+
/**
|
|
18
|
+
* What to do with the waiting marker on the item's label.
|
|
19
|
+
*
|
|
20
|
+
* Only the custom-status path touches labels. A plain 'success' leaves the
|
|
21
|
+
* label alone, so an item previously marked waiting keeps its marker — odd,
|
|
22
|
+
* but existing behaviour, and encoded here rather than quietly changed.
|
|
23
|
+
*/
|
|
24
|
+
label: 'strip' | 'prefix' | 'none';
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Resolve an execution payload into per-test decisions.
|
|
28
|
+
*
|
|
29
|
+
* `outcomeMapping` maps a pytest custom status string onto a run state; unknown
|
|
30
|
+
* or invalid values fall back to 'errored'.
|
|
31
|
+
*
|
|
32
|
+
* Decisions are produced for every run id in the payload. Hosts skip the ones
|
|
33
|
+
* they do not recognise — a run may include tests outside this tree.
|
|
34
|
+
*/
|
|
35
|
+
export declare function resolveExecutionOutcomes(payload: ExecutionTestPayload, outcomeMapping?: Record<string, string>): OutcomeDecision[];
|
|
36
|
+
//# sourceMappingURL=outcomes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"outcomes.d.ts","sourceRoot":"","sources":["../../src/results/outcomes.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AAE9D;;;;;GAKG;AACH,MAAM,MAAM,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,CAAC;AAIhF,8DAA8D;AAC9D,eAAO,MAAM,cAAc,YAAO,CAAC;AAEnC,MAAM,WAAW,eAAe;IAC5B,yDAAyD;IACzD,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,QAAQ,CAAC;IAChB,sDAAsD;IACtD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;;;OAMG;IACH,KAAK,EAAE,OAAO,GAAG,QAAQ,GAAG,MAAM,CAAC;CACtC;AAED;;;;;;;;GAQG;AACH,wBAAgB,wBAAwB,CACpC,OAAO,EAAE,oBAAoB,EAC7B,cAAc,GAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAM,GAC5C,eAAe,EAAE,CAiDnB"}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright (c) 2026 Nigel O'Keefe. All rights reserved.
|
|
3
|
+
// Licensed under the MIT License.
|
|
4
|
+
//
|
|
5
|
+
// Decides what an execution payload means, without applying it.
|
|
6
|
+
//
|
|
7
|
+
// Hosts turn these decisions into whatever their UI needs — TestRun calls, for a
|
|
8
|
+
// VS Code host. Keeping the decision separate is what makes the mapping rules
|
|
9
|
+
// testable without an editor.
|
|
10
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
+
exports.WAITING_PREFIX = void 0;
|
|
12
|
+
exports.resolveExecutionOutcomes = resolveExecutionOutcomes;
|
|
13
|
+
const VALID_STATES = new Set(['passed', 'failed', 'errored', 'skipped', 'enqueued']);
|
|
14
|
+
/** Marker a host may prepend to an item awaiting a result. */
|
|
15
|
+
exports.WAITING_PREFIX = '⏳ ';
|
|
16
|
+
/**
|
|
17
|
+
* Resolve an execution payload into per-test decisions.
|
|
18
|
+
*
|
|
19
|
+
* `outcomeMapping` maps a pytest custom status string onto a run state; unknown
|
|
20
|
+
* or invalid values fall back to 'errored'.
|
|
21
|
+
*
|
|
22
|
+
* Decisions are produced for every run id in the payload. Hosts skip the ones
|
|
23
|
+
* they do not recognise — a run may include tests outside this tree.
|
|
24
|
+
*/
|
|
25
|
+
function resolveExecutionOutcomes(payload, outcomeMapping = {}) {
|
|
26
|
+
const decisions = [];
|
|
27
|
+
for (const [runId, result] of Object.entries(payload.result ?? {})) {
|
|
28
|
+
const outcome = result.outcome ?? 'error';
|
|
29
|
+
const customStatus = result.custom_status;
|
|
30
|
+
switch (outcome) {
|
|
31
|
+
case 'success':
|
|
32
|
+
decisions.push({ runId, state: 'passed', label: 'none' });
|
|
33
|
+
break;
|
|
34
|
+
case 'skipped':
|
|
35
|
+
decisions.push({ runId, state: 'skipped', label: 'none' });
|
|
36
|
+
break;
|
|
37
|
+
case 'failure':
|
|
38
|
+
case 'error':
|
|
39
|
+
if (customStatus) {
|
|
40
|
+
const raw = outcomeMapping[customStatus];
|
|
41
|
+
const state = VALID_STATES.has(raw) ? raw : 'errored';
|
|
42
|
+
decisions.push({
|
|
43
|
+
runId,
|
|
44
|
+
state,
|
|
45
|
+
message: customStatus,
|
|
46
|
+
label: state === 'enqueued' ? 'prefix' : 'strip',
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
decisions.push({
|
|
51
|
+
runId,
|
|
52
|
+
state: 'failed',
|
|
53
|
+
message: result.message ?? result.traceback ?? outcome,
|
|
54
|
+
label: 'none',
|
|
55
|
+
});
|
|
56
|
+
}
|
|
57
|
+
break;
|
|
58
|
+
default:
|
|
59
|
+
decisions.push({ runId, state: 'errored', message: outcome, label: 'none' });
|
|
60
|
+
break;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
// Anything the run never reported on — a crash during collection, say.
|
|
64
|
+
for (const runId of payload.notFound ?? []) {
|
|
65
|
+
decisions.push({ runId, state: 'errored', message: 'Test not found', label: 'none' });
|
|
66
|
+
}
|
|
67
|
+
return decisions;
|
|
68
|
+
}
|
|
69
|
+
//# sourceMappingURL=outcomes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"outcomes.js","sourceRoot":"","sources":["../../src/results/outcomes.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,kCAAkC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ACL,KAAK;wBACL,OAAO,EAAE,YAAY;wBACrB,KAAK,EAAE,KAAK,KAAK,UAAU,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO;qBACnD,CAAC,CAAC;gBACP,CAAC;qBAAM,CAAC;oBACJ,SAAS,CAAC,IAAI,CAAC;wBACX,KAAK;wBACL,KAAK,EAAE,QAAQ;wBACf,OAAO,EAAE,MAAM,CAAC,OAAO,IAAI,MAAM,CAAC,SAAS,IAAI,OAAO;wBACtD,KAAK,EAAE,MAAM;qBAChB,CAAC,CAAC;gBACP,CAAC;gBACD,MAAM;YAEV;gBACI,SAAS,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;gBAC7E,MAAM;QACd,CAAC;IACL,CAAC;IAED,uEAAuE;IACvE,KAAK,MAAM,KAAK,IAAI,OAAO,CAAC,QAAQ,IAAI,EAAE,EAAE,CAAC;QACzC,SAAS,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,gBAAgB,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;IAC1F,CAAC;IAED,OAAO,SAAS,CAAC;AACrB,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { StepDefinition } from '../protocol/types';
|
|
2
|
+
export type GroupingMode = 'file' | 'stepType' | 'tag';
|
|
3
|
+
export declare const UNKNOWN_FILE = "(unknown file)";
|
|
4
|
+
export declare const NO_TYPE = "(no type)";
|
|
5
|
+
export declare const UNTAGGED = "(untagged)";
|
|
6
|
+
export type StepBrowserNode =
|
|
7
|
+
/** An expandable group heading. */
|
|
8
|
+
{
|
|
9
|
+
kind: 'group';
|
|
10
|
+
label: string;
|
|
11
|
+
}
|
|
12
|
+
/** A step, carrying its definition so the host can offer navigation. */
|
|
13
|
+
| {
|
|
14
|
+
kind: 'step';
|
|
15
|
+
label: string;
|
|
16
|
+
step: StepDefinition;
|
|
17
|
+
}
|
|
18
|
+
/** A non-selectable placeholder — nothing discovered, or nothing matched. */
|
|
19
|
+
| {
|
|
20
|
+
kind: 'message';
|
|
21
|
+
label: string;
|
|
22
|
+
};
|
|
23
|
+
export interface BrowseOptions {
|
|
24
|
+
mode: GroupingMode;
|
|
25
|
+
/** Case-insensitive substring match against the step pattern. */
|
|
26
|
+
filter?: string;
|
|
27
|
+
/** Label of the group being expanded. Omitted for the root level. */
|
|
28
|
+
group?: string;
|
|
29
|
+
}
|
|
30
|
+
export declare function filterSteps(steps: StepDefinition[], filter?: string): StepDefinition[];
|
|
31
|
+
/** Distinct group labels, sorted. A step may appear under several. */
|
|
32
|
+
export declare function groupLabels(steps: StepDefinition[], mode: GroupingMode): string[];
|
|
33
|
+
/** Steps belonging to *groupLabel*, sorted by pattern. */
|
|
34
|
+
export declare function stepsInGroup(steps: StepDefinition[], mode: GroupingMode, groupLabel: string): StepDefinition[];
|
|
35
|
+
/**
|
|
36
|
+
* Rows to display.
|
|
37
|
+
*
|
|
38
|
+
* With no `group`, returns the root level: group headings, or a single message
|
|
39
|
+
* when there is nothing to show. With a `group`, returns that group's steps.
|
|
40
|
+
*/
|
|
41
|
+
export declare function browseSteps(allSteps: StepDefinition[], options: BrowseOptions): StepBrowserNode[];
|
|
42
|
+
//# sourceMappingURL=browser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"browser.d.ts","sourceRoot":"","sources":["../../src/steps/browser.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,UAAU,GAAG,KAAK,CAAC;AAEvD,eAAO,MAAM,YAAY,mBAAmB,CAAC;AAC7C,eAAO,MAAM,OAAO,cAAc,CAAC;AACnC,eAAO,MAAM,QAAQ,eAAe,CAAC;AAErC,MAAM,MAAM,eAAe;AACvB,mCAAmC;AACjC;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE;AAClC,wEAAwE;GACtE;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,cAAc,CAAA;CAAE;AACvD,6EAA6E;GAC3E;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAEzC,MAAM,WAAW,aAAa;IAC1B,IAAI,EAAE,YAAY,CAAC;IACnB,iEAAiE;IACjE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,qEAAqE;IACrE,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB;AAcD,wBAAgB,WAAW,CAAC,KAAK,EAAE,cAAc,EAAE,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,cAAc,EAAE,CAItF;AAED,sEAAsE;AACtE,wBAAgB,WAAW,CAAC,KAAK,EAAE,cAAc,EAAE,EAAE,IAAI,EAAE,YAAY,GAAG,MAAM,EAAE,CAQjF;AAED,0DAA0D;AAC1D,wBAAgB,YAAY,CACxB,KAAK,EAAE,cAAc,EAAE,EACvB,IAAI,EAAE,YAAY,EAClB,UAAU,EAAE,MAAM,GACnB,cAAc,EAAE,CAIlB;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CACvB,QAAQ,EAAE,cAAc,EAAE,EAC1B,OAAO,EAAE,aAAa,GACvB,eAAe,EAAE,CAqBnB"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright (c) 2026 Nigel O'Keefe. All rights reserved.
|
|
3
|
+
// Licensed under the MIT License.
|
|
4
|
+
//
|
|
5
|
+
// The step browser's model: what rows to show for a given grouping, filter and
|
|
6
|
+
// expanded group.
|
|
7
|
+
//
|
|
8
|
+
// Returns plain nodes. Rendering them — as a tree view, a list, or anything
|
|
9
|
+
// else — and wiring navigation is the host's job.
|
|
10
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
13
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
14
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
15
|
+
}
|
|
16
|
+
Object.defineProperty(o, k2, desc);
|
|
17
|
+
}) : (function(o, m, k, k2) {
|
|
18
|
+
if (k2 === undefined) k2 = k;
|
|
19
|
+
o[k2] = m[k];
|
|
20
|
+
}));
|
|
21
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
22
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
23
|
+
}) : function(o, v) {
|
|
24
|
+
o["default"] = v;
|
|
25
|
+
});
|
|
26
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
27
|
+
var ownKeys = function(o) {
|
|
28
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
29
|
+
var ar = [];
|
|
30
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
31
|
+
return ar;
|
|
32
|
+
};
|
|
33
|
+
return ownKeys(o);
|
|
34
|
+
};
|
|
35
|
+
return function (mod) {
|
|
36
|
+
if (mod && mod.__esModule) return mod;
|
|
37
|
+
var result = {};
|
|
38
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
39
|
+
__setModuleDefault(result, mod);
|
|
40
|
+
return result;
|
|
41
|
+
};
|
|
42
|
+
})();
|
|
43
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
44
|
+
exports.UNTAGGED = exports.NO_TYPE = exports.UNKNOWN_FILE = void 0;
|
|
45
|
+
exports.filterSteps = filterSteps;
|
|
46
|
+
exports.groupLabels = groupLabels;
|
|
47
|
+
exports.stepsInGroup = stepsInGroup;
|
|
48
|
+
exports.browseSteps = browseSteps;
|
|
49
|
+
const path = __importStar(require("path"));
|
|
50
|
+
exports.UNKNOWN_FILE = '(unknown file)';
|
|
51
|
+
exports.NO_TYPE = '(no type)';
|
|
52
|
+
exports.UNTAGGED = '(untagged)';
|
|
53
|
+
/** The group labels a step belongs under, for a given grouping. */
|
|
54
|
+
function keysFor(step, mode) {
|
|
55
|
+
switch (mode) {
|
|
56
|
+
case 'file':
|
|
57
|
+
return [step.file ? path.basename(step.file) : exports.UNKNOWN_FILE];
|
|
58
|
+
case 'stepType':
|
|
59
|
+
return step.param_types?.length ? [...step.param_types] : [exports.NO_TYPE];
|
|
60
|
+
case 'tag':
|
|
61
|
+
return step.tags?.length ? step.tags.map((t) => `@${t}`) : [exports.UNTAGGED];
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
function filterSteps(steps, filter) {
|
|
65
|
+
const needle = (filter ?? '').toLowerCase().trim();
|
|
66
|
+
if (!needle)
|
|
67
|
+
return steps;
|
|
68
|
+
return steps.filter((s) => s.pattern.toLowerCase().includes(needle));
|
|
69
|
+
}
|
|
70
|
+
/** Distinct group labels, sorted. A step may appear under several. */
|
|
71
|
+
function groupLabels(steps, mode) {
|
|
72
|
+
const labels = new Set();
|
|
73
|
+
for (const step of steps) {
|
|
74
|
+
for (const key of keysFor(step, mode)) {
|
|
75
|
+
labels.add(key);
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
return [...labels].sort();
|
|
79
|
+
}
|
|
80
|
+
/** Steps belonging to *groupLabel*, sorted by pattern. */
|
|
81
|
+
function stepsInGroup(steps, mode, groupLabel) {
|
|
82
|
+
return steps
|
|
83
|
+
.filter((s) => keysFor(s, mode).includes(groupLabel))
|
|
84
|
+
.sort((a, b) => a.pattern.localeCompare(b.pattern));
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* Rows to display.
|
|
88
|
+
*
|
|
89
|
+
* With no `group`, returns the root level: group headings, or a single message
|
|
90
|
+
* when there is nothing to show. With a `group`, returns that group's steps.
|
|
91
|
+
*/
|
|
92
|
+
function browseSteps(allSteps, options) {
|
|
93
|
+
const { mode, filter, group } = options;
|
|
94
|
+
if (allSteps.length === 0) {
|
|
95
|
+
return group ? [] : [{ kind: 'message', label: 'Awaiting discovery...' }];
|
|
96
|
+
}
|
|
97
|
+
const visible = filterSteps(allSteps, filter);
|
|
98
|
+
if (visible.length === 0) {
|
|
99
|
+
return group ? [] : [{ kind: 'message', label: `No steps match "${(filter ?? '').toLowerCase().trim()}"` }];
|
|
100
|
+
}
|
|
101
|
+
if (group === undefined) {
|
|
102
|
+
return groupLabels(visible, mode).map((label) => ({ kind: 'group', label }));
|
|
103
|
+
}
|
|
104
|
+
return stepsInGroup(visible, mode, group).map((step) => ({
|
|
105
|
+
kind: 'step',
|
|
106
|
+
label: step.pattern,
|
|
107
|
+
step,
|
|
108
|
+
}));
|
|
109
|
+
}
|
|
110
|
+
//# sourceMappingURL=browser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"browser.js","sourceRoot":"","sources":["../../src/steps/browser.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,kCAAkC;AAClC,EAAE;AACF,+EAA+E;AAC/E,kBAAkB;AAClB,EAAE;AACF,4EAA4E;AAC5E,kDAAkD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAuClD,kCAIC;AAGD,kCAQC;AAGD,oCAQC;AAQD,kCAwBC;AA/FD,2CAA6B;AAKhB,QAAA,YAAY,GAAG,gBAAgB,CAAC;AAChC,QAAA,OAAO,GAAG,WAAW,CAAC;AACtB,QAAA,QAAQ,GAAG,YAAY,CAAC;AAkBrC,mEAAmE;AACnE,SAAS,OAAO,CAAC,IAAoB,EAAE,IAAkB;IACrD,QAAQ,IAAI,EAAE,CAAC;QACX,KAAK,MAAM;YACP,OAAO,CAAC,IAAI,CAAC,IAAI,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F,CAAC;IAED,OAAO,YAAY,CAAC,OAAO,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;QACrD,IAAI,EAAE,MAAe;QACrB,KAAK,EAAE,IAAI,CAAC,OAAO;QACnB,IAAI;KACP,CAAC,CAAC,CAAC;AACR,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { StepDefinition } from '../protocol/types';
|
|
2
|
+
/**
|
|
3
|
+
* Markdown describing *step*: its pattern, docstring summary, parameters with
|
|
4
|
+
* their suggested values, tags, and where it is defined.
|
|
5
|
+
*
|
|
6
|
+
* Sections are omitted entirely when empty rather than rendered as headings with
|
|
7
|
+
* nothing under them.
|
|
8
|
+
*/
|
|
9
|
+
export declare function renderStepMarkdown(step: StepDefinition): string;
|
|
10
|
+
//# sourceMappingURL=documentation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"documentation.d.ts","sourceRoot":"","sources":["../../src/steps/documentation.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAExD;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,IAAI,EAAE,cAAc,GAAG,MAAM,CA2B/D"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright (c) 2026 Nigel O'Keefe. All rights reserved.
|
|
3
|
+
// Licensed under the MIT License.
|
|
4
|
+
//
|
|
5
|
+
// Renders a step definition as Markdown, for hover documentation or anywhere
|
|
6
|
+
// else a human-readable description of a step is wanted.
|
|
7
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
+
exports.renderStepMarkdown = renderStepMarkdown;
|
|
9
|
+
/**
|
|
10
|
+
* Markdown describing *step*: its pattern, docstring summary, parameters with
|
|
11
|
+
* their suggested values, tags, and where it is defined.
|
|
12
|
+
*
|
|
13
|
+
* Sections are omitted entirely when empty rather than rendered as headings with
|
|
14
|
+
* nothing under them.
|
|
15
|
+
*/
|
|
16
|
+
function renderStepMarkdown(step) {
|
|
17
|
+
const parts = [`**\`${step.pattern}\`**`];
|
|
18
|
+
if (step.summary) {
|
|
19
|
+
parts.push(step.summary);
|
|
20
|
+
}
|
|
21
|
+
if (step.parameters.length > 0) {
|
|
22
|
+
const rows = step.parameters.map((p) => {
|
|
23
|
+
const values = p.suggested_values.length > 0
|
|
24
|
+
? p.suggested_values.join(', ')
|
|
25
|
+
: '_(no suggested values)_';
|
|
26
|
+
return `- \`{${p.name}}\` — **${p.type_name}**: ${values}`;
|
|
27
|
+
});
|
|
28
|
+
parts.push(`**Parameters:**\n\n${rows.join('\n')}`);
|
|
29
|
+
}
|
|
30
|
+
if (step.tags?.length) {
|
|
31
|
+
parts.push(`**Tags:** ${step.tags.map((t) => `\`@${t}\``).join(' ')}`);
|
|
32
|
+
}
|
|
33
|
+
if (step.file) {
|
|
34
|
+
const location = step.line ? `${step.file}:${step.line}` : step.file;
|
|
35
|
+
parts.push(`_Defined in \`${location}\`_`);
|
|
36
|
+
}
|
|
37
|
+
return parts.join('\n\n');
|
|
38
|
+
}
|
|
39
|
+
//# sourceMappingURL=documentation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"documentation.js","sourceRoot":"","sources":["../../src/steps/documentation.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,kCAAkC;AAClC,EAAE;AACF,6EAA6E;AAC7E,yDAAyD;;AAWzD,gDA2BC;AAlCD;;;;;;GAMG;AACH,SAAgB,kBAAkB,CAAC,IAAoB;IACnD,MAAM,KAAK,GAAa,CAAC,OAAO,IAAI,CAAC,OAAO,MAAM,CAAC,CAAC;IAEpD,IAAI,IAAI,CAAC,OAAO,EAAE,CAAC;QACf,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC7B,CAAC;IAED,IAAI,IAAI,CAAC,UAAU,CA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
|
|
5
|
+
* Comments are skipped, and the keyword is stripped before matching so that
|
|
6
|
+
* Given/When/Then/And/But all match the same definition — which is how pytest-bdd
|
|
7
|
+
* resolves them.
|
|
8
|
+
*/
|
|
9
|
+
export declare function findReferencesInLines(lines: string[], step: StepDefinition): number[];
|
|
10
|
+
//# sourceMappingURL=references.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"references.d.ts","sourceRoot":"","sources":["../../src/steps/references.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAMxD;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,IAAI,EAAE,cAAc,GAAG,MAAM,EAAE,CAcrF"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Copyright (c) 2026 Nigel O'Keefe. All rights reserved.
|
|
3
|
+
// Licensed under the MIT License.
|
|
4
|
+
//
|
|
5
|
+
// Finds the lines in a feature file where a given step definition is used.
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.findReferencesInLines = findReferencesInLines;
|
|
8
|
+
const stepCache_1 = require("./stepCache");
|
|
9
|
+
const COMMENT_RE = /^\s*#/;
|
|
10
|
+
const KEYWORD_RE = /^\s*(?:Given|When|Then|And|But|\*)\s+/i;
|
|
11
|
+
/**
|
|
12
|
+
* Zero-indexed lines within *lines* whose step text matches *step*'s pattern.
|
|
13
|
+
*
|
|
14
|
+
* Comments are skipped, and the keyword is stripped before matching so that
|
|
15
|
+
* Given/When/Then/And/But all match the same definition — which is how pytest-bdd
|
|
16
|
+
* resolves them.
|
|
17
|
+
*/
|
|
18
|
+
function findReferencesInLines(lines, step) {
|
|
19
|
+
const rx = (0, stepCache_1.patternToRegex)(step.pattern);
|
|
20
|
+
const results = [];
|
|
21
|
+
for (let i = 0; i < lines.length; i++) {
|
|
22
|
+
const line = lines[i];
|
|
23
|
+
if (COMMENT_RE.test(line))
|
|
24
|
+
continue;
|
|
25
|
+
const m = KEYWORD_RE.exec(line);
|
|
26
|
+
if (!m)
|
|
27
|
+
continue;
|
|
28
|
+
if (rx.test(line.slice(m[0].length).trim())) {
|
|
29
|
+
results.push(i);
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
return results;
|
|
33
|
+
}
|
|
34
|
+
//# sourceMappingURL=references.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"references.js","sourceRoot":"","sources":["../../src/steps/references.ts"],"names":[],"mappings":";AAAA,yDAAyD;AACzD,kCAAkC;AAClC,EAAE;AACF,2EAA2E;;AAe3E,sDAcC;AA1BD,2CAA6C;AAE7C,MAAM,UAAU,GAAG,OAAO,CAAC;AAC3B,MAAM,UAAU,GAAG,wCAAwC,CAAC;AAE5D;;;;;;GAMG;AACH,SAAgB,qBAAqB,CAAC,KAAe,EAAE,IAAoB;IACvE,MAAM,EAAE,GAAG,IAAA,0BAAc,EAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAExC,MAAM,OAAO,GAAa,EAAE,CAAC;IAC7B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACpC,MAAM,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;QACtB,IAAI,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC;YAAE,SAAS;QACpC,MAAM,CAAC,GAAG,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAChC,IAAI,CAAC,CAAC;YAAE,SAAS;QACjB,IAAI,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,CAAC,EAAE,CAAC;YAC1C,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QACpB,CAAC;IACL,CAAC;IACD,OAAO,OAAO,CAAC;AACnB,CAAC"}
|