saucectl authoring schedules
Run test suites created with Sauce AI for Test Authoring on a recurring schedule.
Aliases: schedule, test-schedules
Usage
$ saucectl authoring schedules [command] [flags]
Commands
| Command | Description |
|---|---|
list | List test schedules. |
get | Show a test schedule. |
create | Create a test schedule. |
update | Update a test schedule. |
enable | Resume a suspended schedule. |
disable | Suspend a schedule without deleting it. |
delete | Delete a test schedule. |
All commands also accept the global options, such as --region.
list
List test schedules.
Alias: ls
$ saucectl authoring schedules list [flags]
| Flag | Shorthand | Description |
|---|---|---|
| --out | -o | Output format. Options: text (default) and json. |
| --id | None | Only these schedule IDs. Repeatable. |
| --test-suite-id | None | Only schedules that run this suite. Repeatable. |
| --search | None | Case-insensitive substring match on the schedule name. |
| --start-date | None | Only schedules created on or after this ISO 8601 date. |
| --end-date | None | Only schedules created on or before this ISO 8601 date. |
| --user-id | None | Filter by the ID of the user who created the schedule. |
| --team-id | None | Filter by team ID. |
| --skip | None | Number of results to skip. Default is 0. |
| --limit | None | Maximum number of results to return. Default is 20. Use 0 to return only the total count. |
| --all | None | Return every result, fetching all pages. --limit is ignored. |
saucectl authoring schedules list
saucectl authoring schedules list --test-suite-id <test-suite-id>
get
Show a test schedule.
$ saucectl authoring schedules get <id> [flags]
| Flag | Shorthand | Description |
|---|---|---|
| --out | -o | Output format. Options: text (default) and json. |
saucectl authoring schedules get <schedule-id>
create
Create a test schedule that runs one or more test suites.
--name, --cron, --timezone, and at least one --test-suite-id are required.
$ saucectl authoring schedules create [flags]
| Flag | Shorthand | Description |
|---|---|---|
| --name | None | Required. Name of the schedule, 1 to 255 characters. |
| --cron | None | Required. Six-field cron expression that starts with seconds. For example, "0 0 6 * * 1-5" runs at 06:00 on weekdays. |
| --timezone | None | Required. IANA region/city time zone for the cron expression, for example Europe/Berlin or America/New_York. UTC is not accepted. For a zero offset, use a zone such as Atlantic/Reykjavik. |
| --test-suite-id | None | Required. Suite to run. Repeatable. |
| --running-user-id | None | User that the scheduled runs execute as. Default is you. |
| --state | None | ENABLED or DISABLED (case-insensitive). Default is ENABLED. |
| --start-date | None | ISO 8601 date before which the schedule doesn't run. |
| --end-date | None | ISO 8601 date after which the schedule stops. |
| --max-runs | None | Maximum number of runs before the schedule disables itself. |
| --tunnel-name | None | Sauce Connect tunnel to route scheduled runs through. |
| --build | None | Build name for scheduled runs. |
| --out | -o | Output format. Options: text (default) and json. |
saucectl authoring schedules create --name "Nightly" --cron "0 0 2 * * *" --timezone Europe/Berlin \
--test-suite-id <test-suite-id> --build nightly
saucectl authoring schedules create --name "Smoke" --cron "0 */30 * * * *" --timezone America/New_York \
--test-suite-id <test-suite-id> --max-runs 10 --state disabled
update
Update a test schedule. Only the settings you specify change. saucectl reads the schedule first and sends back its current settings, suites, and state, so an update never erases settings you don't mention.
To change the schedule's suites, either replace the whole list with --test-suite-id, or add and remove individual suites with --add-test-suite-id and --remove-test-suite-id. A schedule must keep at least one suite.
$ saucectl authoring schedules update <id> [flags]
update accepts the same settings flags as create: --name, --cron, --timezone, --running-user-id, --state, --start-date, --end-date, --max-runs, --tunnel-name, and --build. It also accepts the following flags.
| Flag | Shorthand | Description |
|---|---|---|
| --test-suite-id | None | Replace the schedule's suites with these. Repeatable. |
| --add-test-suite-id | None | Add this suite to the schedule. Repeatable. |
| --remove-test-suite-id | None | Remove this suite from the schedule. Repeatable. |
| --unset | None | Clear an optional setting. Options: tunnelName, buildName, startDate, endDate, and maxRuns. Repeatable. You can't set and clear the same setting in one command. |
| --out | -o | Output format. Options: text (default) and json. |
saucectl authoring schedules update <schedule-id> --cron "0 0 3 * * *"
saucectl authoring schedules update <schedule-id> --add-test-suite-id <test-suite-id> --unset maxRuns
saucectl authoring schedules update <schedule-id> --unset tunnelName
enable and disable
enable resumes a suspended schedule. disable suspends a schedule without deleting it. No runs start while a schedule is disabled.
$ saucectl authoring schedules enable <id> [flags]
$ saucectl authoring schedules disable <id> [flags]
| Flag | Shorthand | Description |
|---|---|---|
| --out | -o | Output format. Options: text (default) and json. |
saucectl authoring schedules disable <schedule-id>
saucectl authoring schedules enable <schedule-id>
delete
Delete a test schedule.
Alias: rm
$ saucectl authoring schedules delete <id> [flags]
| Flag | Shorthand | Description |
|---|---|---|
| --yes | -y | Skip the confirmation prompt. Required when saucectl is not running interactively. |
saucectl authoring schedules delete <schedule-id> --yes