@swmansion/argent 0.29.1-next.21 → 0.29.1-next.23
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 +1 -1
- package/dist/cli-cmds.mjs +808 -574
- package/dist/cli.js +3 -2
- package/dist/cli.js.map +1 -1
- package/dist/client.js +389 -226
- package/dist/flow-script-runner.mjs +1 -1
- package/dist/installer.mjs +606 -496
- package/dist/mcp-server.mjs +467 -298
- package/dist/tool-args.generated.d.ts +51 -37
- package/dist/tool-server.cjs +1994 -1738
- package/package.json +1 -1
- package/rules/argent.md +10 -10
- package/skills/{argent-create-flow → argent-create-e2e}/SKILL.md +16 -16
- package/skills/{argent-create-flow/references/flow-yaml.md → argent-create-e2e/references/e2e-yaml.md} +30 -30
- package/skills/{argent-create-flow → argent-create-e2e}/references/live-authoring.md +62 -62
- package/skills/{argent-create-flow → argent-create-e2e}/references/reliability-and-recovery.md +18 -18
- package/skills/argent-device-interact/SKILL.md +2 -2
- package/skills/argent-device-interact/references/chromium.md +1 -1
- package/skills/argent-ios-device-interact/SKILL.md +1 -1
- package/skills/argent-native-profiler/SKILL.md +1 -1
- package/skills/{argent-qa-flows → argent-qa-e2e}/SKILL.md +23 -23
- package/skills/argent-react-native-optimization/SKILL.md +2 -2
- package/skills/argent-react-native-profiler/SKILL.md +3 -3
- package/skills/argent-screen-recording/SKILL.md +1 -1
- package/skills/argent-test-ui-flow/SKILL.md +4 -4
|
@@ -188,84 +188,84 @@ export interface ArgentToolArgs {
|
|
|
188
188
|
/** Number of hours to suppress the update notification */
|
|
189
189
|
hours: number;
|
|
190
190
|
};
|
|
191
|
-
|
|
192
|
-
/**
|
|
193
|
-
udid: string;
|
|
194
|
-
/** The text the focused field must hold afterwards; "" clears it. Supports `{{secret:<NAME>}}` placeholders like `keyboard`. */
|
|
195
|
-
text: string;
|
|
196
|
-
};
|
|
197
|
-
"flow-add-echo": {
|
|
198
|
-
/** Name of the flow being recorded: the one passed to flow-start-recording. */
|
|
191
|
+
"e2e-add-echo": {
|
|
192
|
+
/** Name of the e2e test being recorded: the one passed to e2e-start-recording. */
|
|
199
193
|
name: string;
|
|
200
|
-
/** Absolute path to the project root of the
|
|
194
|
+
/** Absolute path to the project root of the e2e test being recorded: the same value passed to e2e-start-recording. Together with `name` it identifies which recording this echo belongs to. */
|
|
201
195
|
project_root: string;
|
|
202
|
-
/** Message to echo when the
|
|
196
|
+
/** Message to echo when the e2e test is replayed */
|
|
203
197
|
message: string;
|
|
204
198
|
};
|
|
205
|
-
"
|
|
206
|
-
/**
|
|
199
|
+
"e2e-add-script": {
|
|
200
|
+
/** E2E test name passed to e2e-start-recording. */
|
|
207
201
|
name: string;
|
|
208
|
-
/** Absolute project root passed to
|
|
202
|
+
/** Absolute project root passed to e2e-start-recording. */
|
|
209
203
|
project_root: string;
|
|
210
|
-
/** Path to the .mjs file, relative to the
|
|
204
|
+
/** Path to the .mjs file, relative to the e2e test YAML. For example: "../../scripts/seed-order.mjs". */
|
|
211
205
|
path: string;
|
|
212
206
|
/** Optional time limit in milliseconds. The default is 30000 and the minimum is 100. */
|
|
213
207
|
timeout?: number;
|
|
214
208
|
};
|
|
215
|
-
"
|
|
216
|
-
/** Name of the
|
|
209
|
+
"e2e-add-step": {
|
|
210
|
+
/** Name of the e2e test being recorded: the one passed to e2e-start-recording. */
|
|
217
211
|
name: string;
|
|
218
|
-
/** Absolute path to the project root of the
|
|
212
|
+
/** Absolute path to the project root of the e2e test being recorded: the same value passed to e2e-start-recording. Together with `name` it identifies which recording this step belongs to. */
|
|
219
213
|
project_root: string;
|
|
220
|
-
/** MCP tool to execute and record, for example "gesture-tap". Do not pass
|
|
214
|
+
/** MCP tool to execute and record, for example "gesture-tap". Do not pass an e2e test directive or a recording tool. Call e2e-add-script directly for a requested script step. */
|
|
221
215
|
command: string;
|
|
222
216
|
/** Tool arguments as a JSON string, e.g. '{"udid": "ABC", "x": 0.5, "y": 0.3}'. Omit for tools with no arguments. */
|
|
223
217
|
args?: string;
|
|
224
218
|
/** Milliseconds to sleep before executing this step during replay. */
|
|
225
219
|
delayMs?: number;
|
|
226
220
|
};
|
|
227
|
-
"
|
|
228
|
-
/** Name of a saved
|
|
221
|
+
"e2e-execute": {
|
|
222
|
+
/** Name of a saved e2e test to run from `.argent/e2e`, or `.argent/flows` when it is not there (e.g. "settings-explore"). Omit when flow_path is set. */
|
|
229
223
|
name?: string;
|
|
230
|
-
/** Absolute path to the calling agent's project root: the cwd it is working in. With name, the saved
|
|
224
|
+
/** Absolute path to the calling agent's project root: the cwd it is working in. With name, the saved e2e test is read from `.argent/e2e/<name>.yaml`, else `.argent/flows/<name>.yaml`, under this root; with flow_path, the e2e test, its run: siblings, its script: paths and baselines all resolve beside the YAML instead, so pass the agent's cwd. A script still RUNS in this root whichever source was used. */
|
|
231
225
|
project_root: string;
|
|
232
|
-
/** Path to the
|
|
226
|
+
/** Path to the e2e test .yaml as readable by the tool-server. Internal: the argent client derives it from project_root and name automatically; leave unset. */
|
|
233
227
|
flow_file?: string;
|
|
234
|
-
/** Omit when name is set. Absolute path to
|
|
228
|
+
/** Omit when name is set. Absolute path to an e2e test .yaml on the client. Over a link (argent link or ARGENT_TOOLS_URL), the argent client uploads the file, its run: fragments and the snapshot baselines of each run, and the tool-server runs those copies. Keep run: fragments under project_root or beside the e2e test file. With updateBaselines, the client writes the new baselines when the run ends. The client also uploads each absolute .png or .yaml path that a tool: step takes as a file argument, when the file is under project_root or beside the e2e test file. A tool: e2e-execute step that names an e2e test with name and an absolute project_root without a .. segment runs: the client also uploads that e2e test and its own files. Over a link, the uploaded e2e tests must not have: script: steps; tool: steps that run an e2e test another way or record an e2e test; tool: steps that take a directory, an app or an output directory; tool: steps whose tool builds a file path from several arguments; tool: steps that name a relative path or a file other than .png or .yaml. Without a link, the tool-server reads the files in place and all step kinds run. */
|
|
235
229
|
flow_path?: string;
|
|
236
230
|
/** Device id to run against (iOS UDID, Android/Vega serial, Chromium id), as list-devices reports it. Auto-detected when omitted, but only when exactly one booted device matches (optionally narrowed by `platform`); with several booted the run fails and lists them, so pass this explicitly whenever more than one device is up. */
|
|
237
231
|
device?: string;
|
|
238
|
-
/** Restrict auto-detection to this platform when several devices are booted. `ios` selects local simulators only; pass `ios-remote` to select a remote one. `chromium` does more than filter: with no `device` it SELECTS the self-boot branch for
|
|
232
|
+
/** Restrict auto-detection to this platform when several devices are booted. `ios` selects local simulators only; pass `ios-remote` to select a remote one. `chromium` does more than filter: with no `device` it SELECTS the self-boot branch for a standalone e2e test - the runner boots an Electron instance from the `launch` step's chromium value and tears it down after the run (a single-key `launch: { chromium: … }` map selects it on its own, without this parameter). When it selects that branch it never falls back to device auto-detection (a fragment, or a standalone e2e test's launch map with no `chromium` key, still does), and the launch value must be a real Electron app path on the tool-server host: a bare-string `launch:` - what the recorder writes - holds an installed-app bundle id, so passing `chromium` for one fails the whole run with `Electron boot: path does not exist`. Edit the launch to `{ chromium: <app path> }` first. */
|
|
239
233
|
platform?: "ios" | "android" | "chromium" | "vega" | "ios-remote";
|
|
240
|
-
/** Write/refresh screenshot baselines for `snapshot` steps instead of diffing against them, also in the
|
|
234
|
+
/** Write/refresh screenshot baselines for `snapshot` steps instead of diffing against them, also in the e2e tests that tool: e2e-execute steps run, unless such a step sets updateBaselines itself. */
|
|
241
235
|
updateBaselines?: boolean;
|
|
242
236
|
/** Set to true to confirm the execution prerequisite has been met. Required (LLM path) when a fragment defines an executionPrerequisite. */
|
|
243
237
|
prerequisiteAcknowledged?: boolean;
|
|
244
238
|
};
|
|
245
|
-
"
|
|
246
|
-
/** Name of the
|
|
239
|
+
"e2e-finish-recording": {
|
|
240
|
+
/** Name of the e2e test being recorded: the one passed to e2e-start-recording. */
|
|
247
241
|
name: string;
|
|
248
|
-
/** Absolute path to the project root of the
|
|
242
|
+
/** Absolute path to the project root of the e2e test being recorded: the same value passed to e2e-start-recording. Together with `name` it identifies which recording to finish. */
|
|
249
243
|
project_root: string;
|
|
250
244
|
};
|
|
251
|
-
"
|
|
252
|
-
/** Name of a saved
|
|
245
|
+
"e2e-read-prerequisite": {
|
|
246
|
+
/** Name of a saved e2e test to inspect from `.argent/e2e`, or `.argent/flows` when it is not there (e.g. "settings-explore"). Omit when flow_path is set. */
|
|
253
247
|
name?: string;
|
|
254
|
-
/** Absolute path to the calling agent's project root: the cwd it is working in. With name, the saved
|
|
248
|
+
/** Absolute path to the calling agent's project root: the cwd it is working in. With name, the saved e2e test is read from `.argent/e2e/<name>.yaml`, else `.argent/flows/<name>.yaml`, under this root; with flow_path, the prerequisite is read from that YAML instead, so pass the agent's cwd. */
|
|
255
249
|
project_root: string;
|
|
256
|
-
/** Path to the
|
|
250
|
+
/** Path to the e2e test .yaml as readable by the tool-server. Internal: the argent client derives it from project_root and name automatically; leave unset. */
|
|
257
251
|
flow_file?: string;
|
|
258
|
-
/** Omit when name is set. Absolute path to
|
|
252
|
+
/** Omit when name is set. Absolute path to an e2e test .yaml on the client. Over a link (argent link or ARGENT_TOOLS_URL), the argent client uploads the file and the tool-server reads the uploaded copy; without a link, the tool-server reads the file in place. Pass the path through the argent client; a raw path that the file-input boundary did not verify is rejected. Pass the same e2e test source here as to e2e-execute, so the prerequisite you read belongs to the e2e test that will run. */
|
|
259
253
|
flow_path?: string;
|
|
260
254
|
};
|
|
261
|
-
"
|
|
262
|
-
/** Name for this
|
|
255
|
+
"e2e-start-recording": {
|
|
256
|
+
/** Name for this e2e test (e.g. "settings-explore"): letters, digits, underscore and hyphen only. */
|
|
263
257
|
name: string;
|
|
264
|
-
/** Absolute path to the project root directory (the directory that contains or should contain `.argent/
|
|
258
|
+
/** Absolute path to the project root directory (the directory that contains or should contain `.argent/e2e/`). The e2e test file is created at `<project_root>/.argent/e2e/<name>.yaml`. */
|
|
265
259
|
project_root: string;
|
|
266
|
-
/** Fragments only: the app/device state assumed on entry (e.g. "Settings app open on General page"). For a
|
|
260
|
+
/** Fragments only: the app/device state assumed on entry (e.g. "Settings app open on General page"). For a standalone e2e test, omit this and record a `restart-app` as the first step instead; it is captured as the e2e test's `launch` step. restart-app has no chromium support, so a chromium e2e test records as a fragment; add the `launch: { chromium: <app path> }` line to the YAML afterward, deleting the executionPrerequisite line if you passed one, since an e2e test that starts with a launch must not declare it. */
|
|
267
261
|
executionPrerequisite?: string;
|
|
268
262
|
};
|
|
263
|
+
fill: {
|
|
264
|
+
/** Target device id from `list-devices`. */
|
|
265
|
+
udid: string;
|
|
266
|
+
/** The text the focused field must hold afterwards; "" clears it. Supports `{{secret:<NAME>}}` placeholders like `keyboard`. */
|
|
267
|
+
text: string;
|
|
268
|
+
};
|
|
269
269
|
fold: {
|
|
270
270
|
/** Target device id from `list-devices` (a foldable iOS simulator UDID or Android emulator serial). */
|
|
271
271
|
udid: string;
|
|
@@ -893,4 +893,18 @@ export interface ArgentToolArgs {
|
|
|
893
893
|
/** Whether to include the response body (if captured). Defaults to true. */
|
|
894
894
|
includeBody?: boolean;
|
|
895
895
|
};
|
|
896
|
+
/** @deprecated Renamed to `e2e-add-echo`. */
|
|
897
|
+
"flow-add-echo": ArgentToolArgs["e2e-add-echo"];
|
|
898
|
+
/** @deprecated Renamed to `e2e-add-script`. */
|
|
899
|
+
"flow-add-script": ArgentToolArgs["e2e-add-script"];
|
|
900
|
+
/** @deprecated Renamed to `e2e-add-step`. */
|
|
901
|
+
"flow-add-step": ArgentToolArgs["e2e-add-step"];
|
|
902
|
+
/** @deprecated Renamed to `e2e-execute`. */
|
|
903
|
+
"flow-execute": ArgentToolArgs["e2e-execute"];
|
|
904
|
+
/** @deprecated Renamed to `e2e-finish-recording`. */
|
|
905
|
+
"flow-finish-recording": ArgentToolArgs["e2e-finish-recording"];
|
|
906
|
+
/** @deprecated Renamed to `e2e-read-prerequisite`. */
|
|
907
|
+
"flow-read-prerequisite": ArgentToolArgs["e2e-read-prerequisite"];
|
|
908
|
+
/** @deprecated Renamed to `e2e-start-recording`. */
|
|
909
|
+
"flow-start-recording": ArgentToolArgs["e2e-start-recording"];
|
|
896
910
|
}
|