@salesforce/plugin-agent 1.18.1 → 1.18.3
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 +101 -49
- package/lib/commands/agent/generate/template.d.ts +0 -1
- package/lib/commands/agent/generate/template.js +0 -1
- package/lib/commands/agent/generate/template.js.map +1 -1
- package/lib/commands/agent/generate/test-spec.js +5 -5
- package/lib/commands/agent/generate/test-spec.js.map +1 -1
- package/lib/commands/agent/test/create.js +1 -1
- package/lib/commands/agent/test/create.js.map +1 -1
- package/lib/commands/agent/test/list.d.ts +1 -0
- package/lib/commands/agent/test/list.js +1 -0
- package/lib/commands/agent/test/list.js.map +1 -1
- package/messages/agent.generate.test-spec.md +29 -8
- package/messages/agent.test.create.md +23 -11
- package/messages/agent.test.list.md +9 -3
- package/messages/agent.test.run.md +8 -8
- package/npm-shrinkwrap.json +2 -2
- package/oclif.manifest.json +28 -32
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -132,7 +132,7 @@ EXAMPLES
|
|
|
132
132
|
$ sf agent create --agent-name "Resort Manager" --spec specs/resortManagerAgent.yaml --preview
|
|
133
133
|
```
|
|
134
134
|
|
|
135
|
-
_See code: [src/commands/agent/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
135
|
+
_See code: [src/commands/agent/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/create.ts)_
|
|
136
136
|
|
|
137
137
|
## `sf agent generate agent-spec`
|
|
138
138
|
|
|
@@ -237,7 +237,7 @@ EXAMPLES
|
|
|
237
237
|
$ sf agent generate agent-spec --tone formal --agent-user resortmanager@myorg.com
|
|
238
238
|
```
|
|
239
239
|
|
|
240
|
-
_See code: [src/commands/agent/generate/agent-spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
240
|
+
_See code: [src/commands/agent/generate/agent-spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/generate/agent-spec.ts)_
|
|
241
241
|
|
|
242
242
|
## `sf agent generate template`
|
|
243
243
|
|
|
@@ -245,13 +245,10 @@ Generate an agent template from an existing agent in your DX project so you can
|
|
|
245
245
|
|
|
246
246
|
```
|
|
247
247
|
USAGE
|
|
248
|
-
$ sf agent generate template
|
|
249
|
-
<value>]
|
|
248
|
+
$ sf agent generate template --agent-version <value> -f <value> [--json] [--flags-dir <value>] [--api-version <value>]
|
|
250
249
|
|
|
251
250
|
FLAGS
|
|
252
251
|
-f, --agent-file=<value> (required) Path to an agent (Bot) metadata file.
|
|
253
|
-
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
254
|
-
configuration variable is already set.
|
|
255
252
|
--agent-version=<value> (required) Version of the agent (BotVersion).
|
|
256
253
|
--api-version=<value> Override the api version used for api requests made by this command
|
|
257
254
|
|
|
@@ -288,35 +285,65 @@ EXAMPLES
|
|
|
288
285
|
force-app/main/default/bots/My_Awesome_Agent/My_Awesome_Agent.bot-meta.xml --agent-version 1
|
|
289
286
|
```
|
|
290
287
|
|
|
291
|
-
_See code: [src/commands/agent/generate/template.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
288
|
+
_See code: [src/commands/agent/generate/template.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/generate/template.ts)_
|
|
292
289
|
|
|
293
290
|
## `sf agent generate test-spec`
|
|
294
291
|
|
|
295
|
-
|
|
292
|
+
Generate an agent test spec, which is a YAML file that lists the test cases for testing a specific agent.
|
|
296
293
|
|
|
297
294
|
```
|
|
298
295
|
USAGE
|
|
299
296
|
$ sf agent generate test-spec [--flags-dir <value>] [-d <value>] [--force-overwrite] [-f <value>]
|
|
300
297
|
|
|
301
298
|
FLAGS
|
|
302
|
-
-d, --from-definition=<value>
|
|
303
|
-
|
|
304
|
-
|
|
299
|
+
-d, --from-definition=<value> Filepath to the AIEvaluationDefinition metadata XML file in your DX project that you
|
|
300
|
+
want to convert to a test spec YAML file.
|
|
301
|
+
-f, --output-file=<value> Name of the generated test spec YAML file. Default value is
|
|
302
|
+
"specs/<AGENT_API_NAME>-testSpec.yaml".
|
|
303
|
+
--force-overwrite Don't prompt for confirmation when overwriting an existing test spec YAML file.
|
|
305
304
|
|
|
306
305
|
GLOBAL FLAGS
|
|
307
306
|
--flags-dir=<value> Import flag values from a directory.
|
|
308
307
|
|
|
309
308
|
DESCRIPTION
|
|
310
|
-
|
|
309
|
+
Generate an agent test spec, which is a YAML file that lists the test cases for testing a specific agent.
|
|
310
|
+
|
|
311
|
+
The first step when using Salesforce CLI to create an agent test in your org is to use this interactive command to
|
|
312
|
+
generate a local YAML-formatted test spec file. The test spec YAML file contains information about the agent being
|
|
313
|
+
tested, such as its API name, and then one or more test cases. This command uses the metadata components in your DX
|
|
314
|
+
project when prompting for information, such as the agent API name; it doesn't look in your org.
|
|
315
|
+
|
|
316
|
+
To generate a specific agent test case, this command prompts you for this information; when possible, the command
|
|
317
|
+
provides a list of options for you to choose from:
|
|
318
|
+
|
|
319
|
+
- Utterance: Natural language statement, question, or command used to test the agent.
|
|
320
|
+
- Expected topic: API name of the topic you expect the agent to use when responding to the utterance.
|
|
321
|
+
- Expected actions: One or more API names of the expection actions the agent takes.
|
|
322
|
+
- Expected outcome: Natural language description of the outcome you expect.
|
|
311
323
|
|
|
312
|
-
|
|
313
|
-
|
|
324
|
+
When your test spec is ready, you then run the "agent test create" command to actually create the test in your org and
|
|
325
|
+
synchronize the metadata with your DX project. The metadata type for an agent test is AiEvaluationDefinition.
|
|
326
|
+
|
|
327
|
+
If you have an existing AiEvaluationDefinition metadata XML file in your DX project, you can generate its equivalent
|
|
328
|
+
YAML test spec file with the --from-definition flag.
|
|
314
329
|
|
|
315
330
|
EXAMPLES
|
|
316
|
-
|
|
331
|
+
Generate an agent test spec YAML file interactively:
|
|
332
|
+
|
|
333
|
+
$ sf agent generate test-spec
|
|
334
|
+
|
|
335
|
+
Generate an agent test spec YAML file and specify a name for the new file; if the file exists, overwrite it without
|
|
336
|
+
confirmation:
|
|
337
|
+
|
|
338
|
+
$ sf agent generate test-spec --output-file specs/Resort_Manager-new-version-testSpec.yaml --force-overwrite
|
|
339
|
+
|
|
340
|
+
Generate an agent test spec YAML file from an existing AiEvaluationDefinition metadata XML file in your DX project:
|
|
341
|
+
|
|
342
|
+
$ sf agent generate test-spec --from-definition \
|
|
343
|
+
force-app//main/default/aiEvaluationDefinitions/Resort_Manager_Tests.aiEvaluationDefinition-meta.xml
|
|
317
344
|
```
|
|
318
345
|
|
|
319
|
-
_See code: [src/commands/agent/generate/test-spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
346
|
+
_See code: [src/commands/agent/generate/test-spec.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/generate/test-spec.ts)_
|
|
320
347
|
|
|
321
348
|
## `sf agent preview`
|
|
322
349
|
|
|
@@ -351,11 +378,11 @@ FLAG DESCRIPTIONS
|
|
|
351
378
|
the API name of the agent? (TBD based on agents library)
|
|
352
379
|
```
|
|
353
380
|
|
|
354
|
-
_See code: [src/commands/agent/preview.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
381
|
+
_See code: [src/commands/agent/preview.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/preview.ts)_
|
|
355
382
|
|
|
356
383
|
## `sf agent test create`
|
|
357
384
|
|
|
358
|
-
|
|
385
|
+
Create an agent test in your org using a local test spec YAML file.
|
|
359
386
|
|
|
360
387
|
```
|
|
361
388
|
USAGE
|
|
@@ -366,32 +393,51 @@ FLAGS
|
|
|
366
393
|
-o, --target-org=<value> (required) Username or alias of the target org. Not required if the `target-org`
|
|
367
394
|
configuration variable is already set.
|
|
368
395
|
--api-version=<value> Override the api version used for api requests made by this command
|
|
369
|
-
--force-overwrite Don't prompt for confirmation when overwriting an existing test
|
|
370
|
-
|
|
371
|
-
--
|
|
372
|
-
--
|
|
396
|
+
--force-overwrite Don't prompt for confirmation when overwriting an existing test (based on API name) in
|
|
397
|
+
your org.
|
|
398
|
+
--preview Preview the test metadata file (AiEvaluationDefinition) without deploying to your org.
|
|
399
|
+
--spec=<value> Path to the test spec YAML file.
|
|
400
|
+
--test-api-name=<value> API name of the new test; the API name must not exist in the org.
|
|
373
401
|
|
|
374
402
|
GLOBAL FLAGS
|
|
375
403
|
--flags-dir=<value> Import flag values from a directory.
|
|
376
404
|
--json Format output as json.
|
|
377
405
|
|
|
378
406
|
DESCRIPTION
|
|
379
|
-
|
|
407
|
+
Create an agent test in your org using a local test spec YAML file.
|
|
408
|
+
|
|
409
|
+
To run this command, you must have an agent test spec file, which is a YAML file that lists the test cases for testing
|
|
410
|
+
a specific agent. Use the "agent generate test-spec" CLI command to generate a test spec file. Then specify the file
|
|
411
|
+
to this command with the --spec flag, or run this command with no flags to be prompted.
|
|
380
412
|
|
|
381
|
-
|
|
382
|
-
|
|
413
|
+
When this command completes, your org contains the new agent test, which you can view and edit using the Testing
|
|
414
|
+
Center UI. This command also retrieves the metadata component (AiEvaluationDefinition) associated with the new test to
|
|
415
|
+
your local Salesforce DX project and displays its filename.
|
|
383
416
|
|
|
384
|
-
|
|
417
|
+
After you've created the test in the org, use the "agent test run" command to run it.
|
|
385
418
|
|
|
386
419
|
EXAMPLES
|
|
387
|
-
|
|
420
|
+
Create an agent test interactively and be prompted for the test spec and API name of the test in the org; use the
|
|
421
|
+
default org:
|
|
422
|
+
|
|
423
|
+
$ sf agent test create
|
|
424
|
+
|
|
425
|
+
Create an agent test and use flags to specify all required information; if a test with same API name already exists
|
|
426
|
+
in the org, overwrite it without confirmation. Use the org with alias "my-org":
|
|
427
|
+
|
|
428
|
+
$ sf agent test create --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test \
|
|
429
|
+
--force-overwrite --target-org my-org
|
|
430
|
+
|
|
431
|
+
Preview what the agent test metadata (AiEvaluationDefinition) looks like without deploying it to your default org:
|
|
432
|
+
|
|
433
|
+
$ sf agent test create --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test --preview
|
|
388
434
|
```
|
|
389
435
|
|
|
390
|
-
_See code: [src/commands/agent/test/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
436
|
+
_See code: [src/commands/agent/test/create.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/test/create.ts)_
|
|
391
437
|
|
|
392
438
|
## `sf agent test list`
|
|
393
439
|
|
|
394
|
-
List the available tests in
|
|
440
|
+
List the available agent tests in your org.
|
|
395
441
|
|
|
396
442
|
```
|
|
397
443
|
USAGE
|
|
@@ -407,16 +453,22 @@ GLOBAL FLAGS
|
|
|
407
453
|
--json Format output as json.
|
|
408
454
|
|
|
409
455
|
DESCRIPTION
|
|
410
|
-
List the available tests in
|
|
456
|
+
List the available agent tests in your org.
|
|
411
457
|
|
|
412
|
-
|
|
413
|
-
|
|
458
|
+
The command outputs a table with the name (API name) of each test along with its unique ID and the date it was created
|
|
459
|
+
in the org.
|
|
414
460
|
|
|
415
461
|
EXAMPLES
|
|
416
|
-
|
|
462
|
+
List the agent tests in your default org:
|
|
463
|
+
|
|
464
|
+
$ sf agent test list
|
|
465
|
+
|
|
466
|
+
List the agent tests in an org with alias "my-org""
|
|
467
|
+
|
|
468
|
+
$ sf agent test list --target-org my-org
|
|
417
469
|
```
|
|
418
470
|
|
|
419
|
-
_See code: [src/commands/agent/test/list.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
471
|
+
_See code: [src/commands/agent/test/list.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/test/list.ts)_
|
|
420
472
|
|
|
421
473
|
## `sf agent test results`
|
|
422
474
|
|
|
@@ -472,7 +524,7 @@ FLAG DESCRIPTIONS
|
|
|
472
524
|
test results aren't written.
|
|
473
525
|
```
|
|
474
526
|
|
|
475
|
-
_See code: [src/commands/agent/test/results.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
527
|
+
_See code: [src/commands/agent/test/results.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/test/results.ts)_
|
|
476
528
|
|
|
477
529
|
## `sf agent test resume`
|
|
478
530
|
|
|
@@ -535,7 +587,7 @@ FLAG DESCRIPTIONS
|
|
|
535
587
|
test results aren't written.
|
|
536
588
|
```
|
|
537
589
|
|
|
538
|
-
_See code: [src/commands/agent/test/resume.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
590
|
+
_See code: [src/commands/agent/test/resume.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/test/resume.ts)_
|
|
539
591
|
|
|
540
592
|
## `sf agent test run`
|
|
541
593
|
|
|
@@ -564,13 +616,13 @@ GLOBAL FLAGS
|
|
|
564
616
|
DESCRIPTION
|
|
565
617
|
Start an agent test in your org.
|
|
566
618
|
|
|
567
|
-
Use the --name flag to specify the name of the agent test you want to run
|
|
568
|
-
|
|
619
|
+
Use the --name flag to specify the name of the agent test you want to run. Use the output of the "agent test list"
|
|
620
|
+
command to get the names of all the available agent tests in your org.
|
|
569
621
|
|
|
570
|
-
|
|
571
|
-
"agent test resume" command, with a job ID, that you execute to see the results of the test run, and then
|
|
572
|
-
control of the terminal window to you. Use the --wait flag to specify the number of minutes for the command to
|
|
573
|
-
for the agent test to complete; if the test completes by the end of the wait time, the command displays the test
|
|
622
|
+
By default, this command starts the agent test in your org, but it doesn't wait for the test to finish. Instead, it
|
|
623
|
+
displays the "agent test resume" command, with a job ID, that you execute to see the results of the test run, and then
|
|
624
|
+
returns control of the terminal window to you. Use the --wait flag to specify the number of minutes for the command to
|
|
625
|
+
wait for the agent test to complete; if the test completes by the end of the wait time, the command displays the test
|
|
574
626
|
results. If not, run "agent test resume".
|
|
575
627
|
|
|
576
628
|
By default, this command outputs test results in human-readable tables for each test case, if the test completes in
|
|
@@ -579,17 +631,17 @@ DESCRIPTION
|
|
|
579
631
|
to write the results to a file rather than to the terminal.
|
|
580
632
|
|
|
581
633
|
EXAMPLES
|
|
582
|
-
Start
|
|
634
|
+
Start an agent test called Resort_Manager_Test for an agent in your default org, don't wait for the test to finish:
|
|
583
635
|
|
|
584
|
-
$ sf agent test run --name
|
|
636
|
+
$ sf agent test run --name Resort_Manager_Test
|
|
585
637
|
|
|
586
|
-
Start
|
|
638
|
+
Start an agent test for an agent in an org with alias "my-org" and wait for 10 minutes for the test to finish:
|
|
587
639
|
|
|
588
|
-
$ sf agent test run --name
|
|
640
|
+
$ sf agent test run --name Resort_Manager_Test --wait 10 --target-org my-org
|
|
589
641
|
|
|
590
|
-
Start
|
|
642
|
+
Start an agent test and write the JSON-formatted results into a directory called "test-results":
|
|
591
643
|
|
|
592
|
-
$ sf agent test run --name
|
|
644
|
+
$ sf agent test run --name Resort_Manager_Test --wait 10 --output-dir ./test-results --result-format json
|
|
593
645
|
|
|
594
646
|
FLAG DESCRIPTIONS
|
|
595
647
|
-d, --output-dir=<value> Directory to write the agent test results into.
|
|
@@ -598,6 +650,6 @@ FLAG DESCRIPTIONS
|
|
|
598
650
|
test results aren't written.
|
|
599
651
|
```
|
|
600
652
|
|
|
601
|
-
_See code: [src/commands/agent/test/run.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.
|
|
653
|
+
_See code: [src/commands/agent/test/run.ts](https://github.com/salesforcecli/plugin-agent/blob/1.18.3/src/commands/agent/test/run.ts)_
|
|
602
654
|
|
|
603
655
|
<!-- commandsstop -->
|
|
@@ -10,7 +10,6 @@ export default class AgentGenerateTemplate extends SfCommand<AgentGenerateTempla
|
|
|
10
10
|
static state: string;
|
|
11
11
|
static readonly requiresProject = true;
|
|
12
12
|
static readonly flags: {
|
|
13
|
-
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org, import("@oclif/core/interfaces").CustomOptions>;
|
|
14
13
|
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
15
14
|
'agent-version': import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
16
15
|
'agent-file': import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
|
|
@@ -18,7 +18,6 @@ export default class AgentGenerateTemplate extends SfCommand {
|
|
|
18
18
|
static state = 'beta';
|
|
19
19
|
static requiresProject = true;
|
|
20
20
|
static flags = {
|
|
21
|
-
'target-org': Flags.requiredOrg(),
|
|
22
21
|
'api-version': Flags.orgApiVersion(),
|
|
23
22
|
'agent-version': Flags.integer({
|
|
24
23
|
summary: messages.getMessage('flags.agent-version.summary'),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"template.js","sourceRoot":"","sources":["../../../../src/commands/agent/generate/template.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACjE,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAiCxD,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,0BAA0B,EAAE,yBAAyB,CAAC,CAAC;AAM9F,MAAM,CAAC,OAAO,OAAO,qBAAsB,SAAQ,SAAsC;IAChF,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IACjE,MAAM,CAAU,QAAQ,GAAG,QAAQ,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
143
143
|
const outputFile = filePath ??
|
|
144
144
|
(await input({
|
|
145
|
-
message: 'Enter a
|
|
145
|
+
message: 'Enter a filepath for the test spec file',
|
|
146
146
|
validate(d) {
|
|
147
147
|
if (!d.length) {
|
|
148
148
|
return 'Path cannot be empty';
|
|
@@ -237,7 +237,7 @@ export default class AgentGenerateTestSpec extends SfCommand {
|
|
|
237
237
|
theme,
|
|
238
238
|
});
|
|
239
239
|
const subjectName = await select({
|
|
240
|
-
message: 'Select the
|
|
240
|
+
message: 'Select the agent to test',
|
|
241
241
|
choices: bots,
|
|
242
242
|
theme,
|
|
243
243
|
});
|
|
@@ -248,7 +248,7 @@ export default class AgentGenerateTestSpec extends SfCommand {
|
|
|
248
248
|
}
|
|
249
249
|
const { genAiPlugins, genAiFunctions } = await getPluginsAndFunctions(subjectName, cs);
|
|
250
250
|
const name = await input({
|
|
251
|
-
message:
|
|
251
|
+
message: "Enter a name for the test; this name will become the test's label when created in the org",
|
|
252
252
|
validate(d) {
|
|
253
253
|
// ensure that it's not empty
|
|
254
254
|
if (!d.length) {
|
|
@@ -259,7 +259,7 @@ export default class AgentGenerateTestSpec extends SfCommand {
|
|
|
259
259
|
theme,
|
|
260
260
|
});
|
|
261
261
|
const description = await input({
|
|
262
|
-
message: 'Enter a description for test
|
|
262
|
+
message: 'Enter a description for the test (optional)',
|
|
263
263
|
theme,
|
|
264
264
|
});
|
|
265
265
|
const testCases = [];
|
|
@@ -270,7 +270,7 @@ export default class AgentGenerateTestSpec extends SfCommand {
|
|
|
270
270
|
testCases.push(await promptForTestCase(genAiPlugins, genAiFunctions));
|
|
271
271
|
} while ( // eslint-disable-next-line no-await-in-loop
|
|
272
272
|
await confirm({
|
|
273
|
-
message: '
|
|
273
|
+
message: 'Do you want to add another test case',
|
|
274
274
|
default: true,
|
|
275
275
|
}));
|
|
276
276
|
this.log();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"test-spec.js","sourceRoot":"","sources":["../../../../src/commands/agent/gener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IAAI,EAAE;YACjE,SAAS,EAAE,IAAI,CAAC,WAAW,EAAE,MAAM,EAAE,SAAS,EAAE,yBAAyB,CAAC;YAC1E,OAAO,EAAE,KAAK,CAAC,OAAO;SACvB,CAAC,CAAC;QAEH,IAAI,KAAK,CAAC,OAAO,EAAE,CAAC;YAClB,IAAI,CAAC,GAAG,EAAE,MAAM,CAAC,8BAA8B,CAAC,IAAI,CAAC,CAAC;YACtD,IAAI,CAAC,GAAG,EAAE,IAAI,EAAE,CAAC;YACjB,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,UAAU,CAAC,sBAAsB,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAChE,CAAC;aAAM,CAAC;YACN,IAAI,CAAC,GAAG,CACN,QAAQ,CAAC,UAAU,CAAC,cAAc,EAAE,CAAC,IAAI,EAAE,KAAK,CAAC,YAAY,CAAC,CAAC,WAAW,EAAE,IAAI,KAAK,CAAC,YAAY,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CACjH,CAAC;QACJ,CAAC;QAED,OAAO;YACL,IAAI;YACJ,QAAQ;SACT,CAAC;IACJ,CAAC;IAES,KAAK,CAAC,KAAiC;QAC/C,IAAI,CAAC,GAAG,EAAE,KAAK,EAAE,CAAC;QAClB,OAAO,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC5B,CAAC"}
|
|
@@ -5,6 +5,7 @@ export default class AgentTestList extends SfCommand<AgentTestListResult> {
|
|
|
5
5
|
static readonly summary: string;
|
|
6
6
|
static readonly description: string;
|
|
7
7
|
static readonly examples: string[];
|
|
8
|
+
static readonly state = "beta";
|
|
8
9
|
static readonly flags: {
|
|
9
10
|
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org, import("@oclif/core/interfaces").CustomOptions>;
|
|
10
11
|
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
@@ -13,6 +13,7 @@ export default class AgentTestList extends SfCommand {
|
|
|
13
13
|
static summary = messages.getMessage('summary');
|
|
14
14
|
static description = messages.getMessage('description');
|
|
15
15
|
static examples = messages.getMessages('examples');
|
|
16
|
+
static state = 'beta';
|
|
16
17
|
static flags = {
|
|
17
18
|
'target-org': Flags.requiredOrg(),
|
|
18
19
|
'api-version': Flags.orgApiVersion(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../../src/commands/agent/test/list.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,WAAW,EAA4B,MAAM,oBAAoB,CAAC;AAC3E,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,0BAA0B,EAAE,iBAAiB,CAAC,CAAC;AAItF,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,SAA8B;IAChE,MAAM,CAAU,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,SAAS,CAAC,CAAC;IACzD,MAAM,CAAU,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;IACjE,MAAM,CAAU,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../../src/commands/agent/test/list.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,WAAW,EAA4B,MAAM,oBAAoB,CAAC;AAC3E,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C,QAAQ,CAAC,k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IACjB,CAAC"}
|
|
@@ -1,26 +1,47 @@
|
|
|
1
1
|
# summary
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Generate an agent test spec, which is a YAML file that lists the test cases for testing a specific agent.
|
|
4
4
|
|
|
5
5
|
# description
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
The first step when using Salesforce CLI to create an agent test in your org is to use this interactive command to generate a local YAML-formatted test spec file. The test spec YAML file contains information about the agent being tested, such as its API name, and then one or more test cases. This command uses the metadata components in your DX project when prompting for information, such as the agent API name; it doesn't look in your org.
|
|
8
|
+
|
|
9
|
+
To generate a specific agent test case, this command prompts you for this information; when possible, the command provides a list of options for you to choose from:
|
|
10
|
+
|
|
11
|
+
- Utterance: Natural language statement, question, or command used to test the agent.
|
|
12
|
+
- Expected topic: API name of the topic you expect the agent to use when responding to the utterance.
|
|
13
|
+
- Expected actions: One or more API names of the expection actions the agent takes.
|
|
14
|
+
- Expected outcome: Natural language description of the outcome you expect.
|
|
15
|
+
|
|
16
|
+
When your test spec is ready, you then run the "agent test create" command to actually create the test in your org and synchronize the metadata with your DX project. The metadata type for an agent test is AiEvaluationDefinition.
|
|
17
|
+
|
|
18
|
+
If you have an existing AiEvaluationDefinition metadata XML file in your DX project, you can generate its equivalent YAML test spec file with the --from-definition flag.
|
|
8
19
|
|
|
9
20
|
# flags.from-definition.summary
|
|
10
21
|
|
|
11
|
-
|
|
22
|
+
Filepath to the AIEvaluationDefinition metadata XML file in your DX project that you want to convert to a test spec YAML file.
|
|
12
23
|
|
|
13
24
|
# flags.force-overwrite.summary
|
|
14
25
|
|
|
15
|
-
Don't prompt for confirmation when overwriting an existing test spec file.
|
|
26
|
+
Don't prompt for confirmation when overwriting an existing test spec YAML file.
|
|
16
27
|
|
|
17
28
|
# flags.output-file.summary
|
|
18
29
|
|
|
19
|
-
|
|
30
|
+
Name of the generated test spec YAML file. Default value is "specs/<AGENT_API_NAME>-testSpec.yaml".
|
|
20
31
|
|
|
21
32
|
# examples
|
|
22
33
|
|
|
23
|
-
-
|
|
34
|
+
- Generate an agent test spec YAML file interactively:
|
|
35
|
+
|
|
36
|
+
<%= config.bin %> <%= command.id %>
|
|
37
|
+
|
|
38
|
+
- Generate an agent test spec YAML file and specify a name for the new file; if the file exists, overwrite it without confirmation:
|
|
39
|
+
|
|
40
|
+
<%= config.bin %> <%= command.id %> --output-file specs/Resort_Manager-new-version-testSpec.yaml --force-overwrite
|
|
41
|
+
|
|
42
|
+
- Generate an agent test spec YAML file from an existing AiEvaluationDefinition metadata XML file in your DX project:
|
|
43
|
+
|
|
44
|
+
<%= config.bin %> <%= command.id %> --from-definition force-app//main/default/aiEvaluationDefinitions/Resort_Manager_Tests.aiEvaluationDefinition-meta.xml
|
|
24
45
|
|
|
25
46
|
# info.cancel
|
|
26
47
|
|
|
@@ -28,8 +49,8 @@ Operation canceled.
|
|
|
28
49
|
|
|
29
50
|
# error.InvalidAiEvaluationDefinition
|
|
30
51
|
|
|
31
|
-
File must be an AiEvaluationDefinition metadata file
|
|
52
|
+
File must be an AiEvaluationDefinition metadata XML file.
|
|
32
53
|
|
|
33
54
|
# error.NoAgentsFound
|
|
34
55
|
|
|
35
|
-
No agents found in %s
|
|
56
|
+
No agents found in %s.
|
|
@@ -1,44 +1,56 @@
|
|
|
1
1
|
# summary
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Create an agent test in your org using a local test spec YAML file.
|
|
4
4
|
|
|
5
5
|
# description
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
To run this command, you must have an agent test spec file, which is a YAML file that lists the test cases for testing a specific agent. Use the "agent generate test-spec" CLI command to generate a test spec file. Then specify the file to this command with the --spec flag, or run this command with no flags to be prompted.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
When this command completes, your org contains the new agent test, which you can view and edit using the Testing Center UI. This command also retrieves the metadata component (AiEvaluationDefinition) associated with the new test to your local Salesforce DX project and displays its filename.
|
|
10
|
+
|
|
11
|
+
After you've created the test in the org, use the "agent test run" command to run it.
|
|
10
12
|
|
|
11
13
|
# flags.spec.summary
|
|
12
14
|
|
|
13
|
-
|
|
15
|
+
Path to the test spec YAML file.
|
|
14
16
|
|
|
15
17
|
# flags.preview.summary
|
|
16
18
|
|
|
17
|
-
Preview the test metadata without deploying to your org.
|
|
19
|
+
Preview the test metadata file (AiEvaluationDefinition) without deploying to your org.
|
|
18
20
|
|
|
19
21
|
# flags.force-overwrite.summary
|
|
20
22
|
|
|
21
|
-
Don't prompt for confirmation when overwriting an existing test.
|
|
23
|
+
Don't prompt for confirmation when overwriting an existing test (based on API name) in your org.
|
|
22
24
|
|
|
23
25
|
# flags.test-api-name.summary
|
|
24
26
|
|
|
25
|
-
|
|
27
|
+
API name of the new test; the API name must not exist in the org.
|
|
26
28
|
|
|
27
29
|
# examples
|
|
28
30
|
|
|
29
|
-
-
|
|
31
|
+
- Create an agent test interactively and be prompted for the test spec and API name of the test in the org; use the default org:
|
|
32
|
+
|
|
33
|
+
<%= config.bin %> <%= command.id %>
|
|
34
|
+
|
|
35
|
+
- Create an agent test and use flags to specify all required information; if a test with same API name already exists in the org, overwrite it without confirmation. Use the org with alias "my-org":
|
|
36
|
+
|
|
37
|
+
<%= config.bin %> <%= command.id %> --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test --force-overwrite --target-org my-org
|
|
38
|
+
|
|
39
|
+
- Preview what the agent test metadata (AiEvaluationDefinition) looks like without deploying it to your default org:
|
|
40
|
+
|
|
41
|
+
<%= config.bin %> <%= command.id %> --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test --preview
|
|
30
42
|
|
|
31
43
|
# prompt.confirm
|
|
32
44
|
|
|
33
|
-
|
|
45
|
+
A test with the API name %s already exists in the org. Do you want to overwrite it?
|
|
34
46
|
|
|
35
47
|
# info.success
|
|
36
48
|
|
|
37
|
-
AiEvaluationDefinition created at %s and deployed to %s
|
|
49
|
+
Local AiEvaluationDefinition metadata XML file created at %s and agent test deployed to %s.
|
|
38
50
|
|
|
39
51
|
# info.preview-success
|
|
40
52
|
|
|
41
|
-
Preview of
|
|
53
|
+
Preview of of the test created at %s.
|
|
42
54
|
|
|
43
55
|
# error.missingRequiredFlags
|
|
44
56
|
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
# summary
|
|
2
2
|
|
|
3
|
-
List the available tests in
|
|
3
|
+
List the available agent tests in your org.
|
|
4
4
|
|
|
5
5
|
# description
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
The command outputs a table with the name (API name) of each test along with its unique ID and the date it was created in the org.
|
|
8
8
|
|
|
9
9
|
# examples
|
|
10
10
|
|
|
11
|
-
-
|
|
11
|
+
- List the agent tests in your default org:
|
|
12
|
+
|
|
13
|
+
<%= config.bin %> <%= command.id %>
|
|
14
|
+
|
|
15
|
+
- List the agent tests in an org with alias "my-org""
|
|
16
|
+
|
|
17
|
+
<%= config.bin %> <%= command.id %> --target-org my-org
|
|
@@ -4,9 +4,9 @@ Start an agent test in your org.
|
|
|
4
4
|
|
|
5
5
|
# description
|
|
6
6
|
|
|
7
|
-
Use the --name flag to specify the name of the agent test you want to run
|
|
7
|
+
Use the --name flag to specify the name of the agent test you want to run. Use the output of the "agent test list" command to get the names of all the available agent tests in your org.
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
By default, this command starts the agent test in your org, but it doesn't wait for the test to finish. Instead, it displays the "agent test resume" command, with a job ID, that you execute to see the results of the test run, and then returns control of the terminal window to you. Use the --wait flag to specify the number of minutes for the command to wait for the agent test to complete; if the test completes by the end of the wait time, the command displays the test results. If not, run "agent test resume".
|
|
10
10
|
|
|
11
11
|
By default, this command outputs test results in human-readable tables for each test case, if the test completes in time. The tables show whether the test case passed, the expected and actual values, the test score, how long the test took, and more. Use the --result-format to display the test results in JSON or Junit format. Use the --output-dir flag to write the results to a file rather than to the terminal.
|
|
12
12
|
|
|
@@ -20,14 +20,14 @@ Number of minutes to wait for the command to complete and display results to the
|
|
|
20
20
|
|
|
21
21
|
# examples
|
|
22
22
|
|
|
23
|
-
- Start
|
|
23
|
+
- Start an agent test called Resort_Manager_Test for an agent in your default org, don't wait for the test to finish:
|
|
24
24
|
|
|
25
|
-
<%= config.bin %> <%= command.id %> --name
|
|
25
|
+
<%= config.bin %> <%= command.id %> --name Resort_Manager_Test
|
|
26
26
|
|
|
27
|
-
- Start
|
|
27
|
+
- Start an agent test for an agent in an org with alias "my-org" and wait for 10 minutes for the test to finish:
|
|
28
28
|
|
|
29
|
-
<%= config.bin %> <%= command.id %> --name
|
|
29
|
+
<%= config.bin %> <%= command.id %> --name Resort_Manager_Test --wait 10 --target-org my-org
|
|
30
30
|
|
|
31
|
-
- Start
|
|
31
|
+
- Start an agent test and write the JSON-formatted results into a directory called "test-results":
|
|
32
32
|
|
|
33
|
-
<%= config.bin %> <%= command.id %> --name
|
|
33
|
+
<%= config.bin %> <%= command.id %> --name Resort_Manager_Test --wait 10 --output-dir ./test-results --result-format json
|
package/npm-shrinkwrap.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/plugin-agent",
|
|
3
|
-
"version": "1.18.
|
|
3
|
+
"version": "1.18.3",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "@salesforce/plugin-agent",
|
|
9
|
-
"version": "1.18.
|
|
9
|
+
"version": "1.18.3",
|
|
10
10
|
"license": "BSD-3-Clause",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@inquirer/core": "^10.1.6",
|
package/oclif.manifest.json
CHANGED
|
@@ -387,16 +387,6 @@
|
|
|
387
387
|
"multiple": false,
|
|
388
388
|
"type": "option"
|
|
389
389
|
},
|
|
390
|
-
"target-org": {
|
|
391
|
-
"char": "o",
|
|
392
|
-
"name": "target-org",
|
|
393
|
-
"noCacheDefault": true,
|
|
394
|
-
"required": true,
|
|
395
|
-
"summary": "Username or alias of the target org. Not required if the `target-org` configuration variable is already set.",
|
|
396
|
-
"hasDynamicHelp": true,
|
|
397
|
-
"multiple": false,
|
|
398
|
-
"type": "option"
|
|
399
|
-
},
|
|
400
390
|
"api-version": {
|
|
401
391
|
"description": "Override the api version used for api requests made by this command",
|
|
402
392
|
"name": "api-version",
|
|
@@ -422,7 +412,7 @@
|
|
|
422
412
|
"type": "option"
|
|
423
413
|
}
|
|
424
414
|
},
|
|
425
|
-
"hasDynamicHelp":
|
|
415
|
+
"hasDynamicHelp": false,
|
|
426
416
|
"hiddenAliases": [],
|
|
427
417
|
"id": "agent:generate:template",
|
|
428
418
|
"pluginAlias": "@salesforce/plugin-agent",
|
|
@@ -454,9 +444,11 @@
|
|
|
454
444
|
"agent:generate:test-spec": {
|
|
455
445
|
"aliases": [],
|
|
456
446
|
"args": {},
|
|
457
|
-
"description": "
|
|
447
|
+
"description": "The first step when using Salesforce CLI to create an agent test in your org is to use this interactive command to generate a local YAML-formatted test spec file. The test spec YAML file contains information about the agent being tested, such as its API name, and then one or more test cases. This command uses the metadata components in your DX project when prompting for information, such as the agent API name; it doesn't look in your org.\n\nTo generate a specific agent test case, this command prompts you for this information; when possible, the command provides a list of options for you to choose from:\n\n- Utterance: Natural language statement, question, or command used to test the agent.\n- Expected topic: API name of the topic you expect the agent to use when responding to the utterance.\n- Expected actions: One or more API names of the expection actions the agent takes.\n- Expected outcome: Natural language description of the outcome you expect.\n\nWhen your test spec is ready, you then run the \"agent test create\" command to actually create the test in your org and synchronize the metadata with your DX project. The metadata type for an agent test is AiEvaluationDefinition.\n\nIf you have an existing AiEvaluationDefinition metadata XML file in your DX project, you can generate its equivalent YAML test spec file with the --from-definition flag.",
|
|
458
448
|
"examples": [
|
|
459
|
-
"<%= config.bin %> <%= command.id %>"
|
|
449
|
+
"Generate an agent test spec YAML file interactively:\n<%= config.bin %> <%= command.id %>",
|
|
450
|
+
"Generate an agent test spec YAML file and specify a name for the new file; if the file exists, overwrite it without confirmation:\n<%= config.bin %> <%= command.id %> --output-file specs/Resort_Manager-new-version-testSpec.yaml --force-overwrite",
|
|
451
|
+
"Generate an agent test spec YAML file from an existing AiEvaluationDefinition metadata XML file in your DX project:\n<%= config.bin %> <%= command.id %> --from-definition force-app//main/default/aiEvaluationDefinitions/Resort_Manager_Tests.aiEvaluationDefinition-meta.xml"
|
|
460
452
|
],
|
|
461
453
|
"flags": {
|
|
462
454
|
"flags-dir": {
|
|
@@ -470,21 +462,21 @@
|
|
|
470
462
|
"from-definition": {
|
|
471
463
|
"char": "d",
|
|
472
464
|
"name": "from-definition",
|
|
473
|
-
"summary": "
|
|
465
|
+
"summary": "Filepath to the AIEvaluationDefinition metadata XML file in your DX project that you want to convert to a test spec YAML file.",
|
|
474
466
|
"hasDynamicHelp": false,
|
|
475
467
|
"multiple": false,
|
|
476
468
|
"type": "option"
|
|
477
469
|
},
|
|
478
470
|
"force-overwrite": {
|
|
479
471
|
"name": "force-overwrite",
|
|
480
|
-
"summary": "Don't prompt for confirmation when overwriting an existing test spec file.",
|
|
472
|
+
"summary": "Don't prompt for confirmation when overwriting an existing test spec YAML file.",
|
|
481
473
|
"allowNo": false,
|
|
482
474
|
"type": "boolean"
|
|
483
475
|
},
|
|
484
476
|
"output-file": {
|
|
485
477
|
"char": "f",
|
|
486
478
|
"name": "output-file",
|
|
487
|
-
"summary": "
|
|
479
|
+
"summary": "Name of the generated test spec YAML file. Default value is \"specs/<AGENT_API_NAME>-testSpec.yaml\".",
|
|
488
480
|
"hasDynamicHelp": false,
|
|
489
481
|
"multiple": false,
|
|
490
482
|
"type": "option"
|
|
@@ -498,7 +490,7 @@
|
|
|
498
490
|
"pluginType": "core",
|
|
499
491
|
"state": "beta",
|
|
500
492
|
"strict": true,
|
|
501
|
-
"summary": "
|
|
493
|
+
"summary": "Generate an agent test spec, which is a YAML file that lists the test cases for testing a specific agent.",
|
|
502
494
|
"enableJsonFlag": false,
|
|
503
495
|
"isESM": true,
|
|
504
496
|
"relativePath": [
|
|
@@ -607,9 +599,11 @@
|
|
|
607
599
|
"agent:test:create": {
|
|
608
600
|
"aliases": [],
|
|
609
601
|
"args": {},
|
|
610
|
-
"description": "
|
|
602
|
+
"description": "To run this command, you must have an agent test spec file, which is a YAML file that lists the test cases for testing a specific agent. Use the \"agent generate test-spec\" CLI command to generate a test spec file. Then specify the file to this command with the --spec flag, or run this command with no flags to be prompted.\n\nWhen this command completes, your org contains the new agent test, which you can view and edit using the Testing Center UI. This command also retrieves the metadata component (AiEvaluationDefinition) associated with the new test to your local Salesforce DX project and displays its filename.\n\nAfter you've created the test in the org, use the \"agent test run\" command to run it.",
|
|
611
603
|
"examples": [
|
|
612
|
-
"<%= config.bin %> <%= command.id %>"
|
|
604
|
+
"Create an agent test interactively and be prompted for the test spec and API name of the test in the org; use the default org:\n<%= config.bin %> <%= command.id %>",
|
|
605
|
+
"Create an agent test and use flags to specify all required information; if a test with same API name already exists in the org, overwrite it without confirmation. Use the org with alias \"my-org\":\n<%= config.bin %> <%= command.id %> --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test --force-overwrite --target-org my-org",
|
|
606
|
+
"Preview what the agent test metadata (AiEvaluationDefinition) looks like without deploying it to your default org:\n<%= config.bin %> <%= command.id %> --spec specs/Resort_Manager-testSpec.yaml --test-api-name Resort_Manager_Test --preview"
|
|
613
607
|
],
|
|
614
608
|
"flags": {
|
|
615
609
|
"json": {
|
|
@@ -629,14 +623,14 @@
|
|
|
629
623
|
},
|
|
630
624
|
"test-api-name": {
|
|
631
625
|
"name": "test-api-name",
|
|
632
|
-
"summary": "
|
|
626
|
+
"summary": "API name of the new test; the API name must not exist in the org.",
|
|
633
627
|
"hasDynamicHelp": false,
|
|
634
628
|
"multiple": false,
|
|
635
629
|
"type": "option"
|
|
636
630
|
},
|
|
637
631
|
"spec": {
|
|
638
632
|
"name": "spec",
|
|
639
|
-
"summary": "
|
|
633
|
+
"summary": "Path to the test spec YAML file.",
|
|
640
634
|
"hasDynamicHelp": false,
|
|
641
635
|
"multiple": false,
|
|
642
636
|
"type": "option"
|
|
@@ -660,13 +654,13 @@
|
|
|
660
654
|
},
|
|
661
655
|
"preview": {
|
|
662
656
|
"name": "preview",
|
|
663
|
-
"summary": "Preview the test metadata without deploying to your org.",
|
|
657
|
+
"summary": "Preview the test metadata file (AiEvaluationDefinition) without deploying to your org.",
|
|
664
658
|
"allowNo": false,
|
|
665
659
|
"type": "boolean"
|
|
666
660
|
},
|
|
667
661
|
"force-overwrite": {
|
|
668
662
|
"name": "force-overwrite",
|
|
669
|
-
"summary": "Don't prompt for confirmation when overwriting an existing test.",
|
|
663
|
+
"summary": "Don't prompt for confirmation when overwriting an existing test (based on API name) in your org.",
|
|
670
664
|
"allowNo": false,
|
|
671
665
|
"type": "boolean"
|
|
672
666
|
}
|
|
@@ -679,7 +673,7 @@
|
|
|
679
673
|
"pluginType": "core",
|
|
680
674
|
"state": "beta",
|
|
681
675
|
"strict": true,
|
|
682
|
-
"summary": "
|
|
676
|
+
"summary": "Create an agent test in your org using a local test spec YAML file.",
|
|
683
677
|
"enableJsonFlag": true,
|
|
684
678
|
"isESM": true,
|
|
685
679
|
"relativePath": [
|
|
@@ -702,9 +696,10 @@
|
|
|
702
696
|
"agent:test:list": {
|
|
703
697
|
"aliases": [],
|
|
704
698
|
"args": {},
|
|
705
|
-
"description": "
|
|
699
|
+
"description": "The command outputs a table with the name (API name) of each test along with its unique ID and the date it was created in the org.",
|
|
706
700
|
"examples": [
|
|
707
|
-
"<%= config.bin %> <%= command.id %>"
|
|
701
|
+
"List the agent tests in your default org:\n<%= config.bin %> <%= command.id %>",
|
|
702
|
+
"List the agent tests in an org with alias \"my-org\"\"\n<%= config.bin %> <%= command.id %> --target-org my-org"
|
|
708
703
|
],
|
|
709
704
|
"flags": {
|
|
710
705
|
"json": {
|
|
@@ -746,8 +741,9 @@
|
|
|
746
741
|
"pluginAlias": "@salesforce/plugin-agent",
|
|
747
742
|
"pluginName": "@salesforce/plugin-agent",
|
|
748
743
|
"pluginType": "core",
|
|
744
|
+
"state": "beta",
|
|
749
745
|
"strict": true,
|
|
750
|
-
"summary": "List the available tests in
|
|
746
|
+
"summary": "List the available agent tests in your org.",
|
|
751
747
|
"enableJsonFlag": true,
|
|
752
748
|
"isESM": true,
|
|
753
749
|
"relativePath": [
|
|
@@ -991,11 +987,11 @@
|
|
|
991
987
|
"agent:test:run": {
|
|
992
988
|
"aliases": [],
|
|
993
989
|
"args": {},
|
|
994
|
-
"description": "Use the --name flag to specify the name of the agent test you want to run
|
|
990
|
+
"description": "Use the --name flag to specify the name of the agent test you want to run. Use the output of the \"agent test list\" command to get the names of all the available agent tests in your org.\n\nBy default, this command starts the agent test in your org, but it doesn't wait for the test to finish. Instead, it displays the \"agent test resume\" command, with a job ID, that you execute to see the results of the test run, and then returns control of the terminal window to you. Use the --wait flag to specify the number of minutes for the command to wait for the agent test to complete; if the test completes by the end of the wait time, the command displays the test results. If not, run \"agent test resume\".\n\nBy default, this command outputs test results in human-readable tables for each test case, if the test completes in time. The tables show whether the test case passed, the expected and actual values, the test score, how long the test took, and more. Use the --result-format to display the test results in JSON or Junit format. Use the --output-dir flag to write the results to a file rather than to the terminal.",
|
|
995
991
|
"examples": [
|
|
996
|
-
"Start
|
|
997
|
-
"Start
|
|
998
|
-
"Start
|
|
992
|
+
"Start an agent test called Resort_Manager_Test for an agent in your default org, don't wait for the test to finish:\n<%= config.bin %> <%= command.id %> --name Resort_Manager_Test",
|
|
993
|
+
"Start an agent test for an agent in an org with alias \"my-org\" and wait for 10 minutes for the test to finish:\n<%= config.bin %> <%= command.id %> --name Resort_Manager_Test --wait 10 --target-org my-org",
|
|
994
|
+
"Start an agent test and write the JSON-formatted results into a directory called \"test-results\":\n<%= config.bin %> <%= command.id %> --name Resort_Manager_Test --wait 10 --output-dir ./test-results --result-format json"
|
|
999
995
|
],
|
|
1000
996
|
"flags": {
|
|
1001
997
|
"json": {
|
|
@@ -1100,5 +1096,5 @@
|
|
|
1100
1096
|
]
|
|
1101
1097
|
}
|
|
1102
1098
|
},
|
|
1103
|
-
"version": "1.18.
|
|
1099
|
+
"version": "1.18.3"
|
|
1104
1100
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/plugin-agent",
|
|
3
3
|
"description": "Commands to interact with Salesforce agents",
|
|
4
|
-
"version": "1.18.
|
|
4
|
+
"version": "1.18.3",
|
|
5
5
|
"author": "Salesforce",
|
|
6
6
|
"bugs": "https://github.com/forcedotcom/cli/issues",
|
|
7
7
|
"dependencies": {
|
|
@@ -229,7 +229,7 @@
|
|
|
229
229
|
"exports": "./lib/index.js",
|
|
230
230
|
"type": "module",
|
|
231
231
|
"sfdx": {
|
|
232
|
-
"publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-agent/1.18.
|
|
233
|
-
"signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-agent/1.18.
|
|
232
|
+
"publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-agent/1.18.3.crt",
|
|
233
|
+
"signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-agent/1.18.3.sig"
|
|
234
234
|
}
|
|
235
235
|
}
|