Schedule jobs
A job is a test or set of tests that runs at a specified schedule. You can schedule a job to run at a designated time and/or with a recurrence pattern of hourly, daily, weekly, and so on. You can also configure a job to send an email or SMS for each successful, aborted, or unsuccessful job execution.
Each user can maintain up to 20 scheduled executions.
The Scheduled Jobs view displays a list of all jobs currently scheduled to run. The list appears in a tabular format and shows individual job details like the name of the job, owner of the job, job enablement status, recurrence, last run, next scheduled run, and notification status.
In the Scheduled Jobs view, you can view, add, edit, and delete scheduled jobs. You can also enable or disable a job schedule. To search for a specific job schedule, you can use the available search box.
For information about a job's status, hover over the icon next to the last run. If you click the last run of a job, the Report Library opens, showing the respective status of all tests in the job. You can click the individual tests to view the execution details.
After the job execution, the CI Dashboard displays the job details. When you click the job name, the Report Library view shows the corresponding job details. For jobs with multiple tests, you can view details of all test executions by clicking the tests.
You can configure Scriptless Mobile to receive email notifications for your jobs. The email contains a link that directs you to the Report Library, which shows details of the job execution.
For a job with multiple tests, the job status depends on the test execution status, as shown in the following table:
Job status | Test execution status |
---|---|
Passed |
All test executions passed |
Failed |
One or more test executions failed |
Blocked |
No test execution failed, but at least one is blocked |
To learn how to create a job and how to view, modify, enable, disable, and delete scheduled jobs, review the following information.
To learn how to add jobs and manage scheduled jobs, watch this short video. To view detailed steps, expand the relevant procedure following the video.

When adding a job, you can configure runtime values, select a device, and configure a schedule to run a job.
-
Near the Perfecto logo, on the top toolbar, click Scheduler
and select Schedule new job.
-
Click Add tests.
-
In the Configure tests dialog box, in the left pane, expand the folders and select the checkbox next to the required test or folder. Selecting a folder selects all tests in the folder.
You can select either tests or folders or both tests and folders. Click Select.
Important: You can set the limit for the number of tests a job can include. To set the number of tests per job for your cloud, contact Perfecto Support.The left pane displays the list of selected tests. The list does not display folders but includes the tests in the folders. You can perform the following actions if required:
-
To delete a test from your job, click the Remove test from schedule button
next to it.
-
To add a test or folder to the existing list, click Add tests. Select the folders or tests and then click Select.
When you select a test, the right pane displays the corresponding list of runtime variables. You can configure these variables.
-
-
To add a value to a runtime variable, select the test. In the list of runtime variables, go to the individual variables and add values.
A warning icon appears for a test when one or more runtime variables do not have specified values.
Restriction: A job with multiple tests does not support Datatables marked as runtime variables. -
Click APPLY.
-
(Optional) Back in the main view, you can try the following actions if required:
-
To change the sequence of the test execution, drag a test up or down using the tile button
next to it. The test execution occurs in the selected order.
-
To view the source location of a test, hover over the test.
-
To edit the runtime variables for a test, click the edit button
next to it.
-
To delete a test from your job, click the Remove test from schedule button
next to it.
You can run each test on a separate device or use a single device for all test executions.
-
-
To execute all tests on a single device, turn on the Use a single device for all tests in this job toggle.
Important: Enabling this option replaces the DUT variable value in all tests with the device you add here.-
Click Add device.
-
In the Select device dialog box, select a device and click SELECT.
If you want to remove the selected device, click the delete button
next to the device.
-
-
To receive job-related notifications, on the right, under Allow Notifications, do the following:
-
Turn on the By email or By SMS toggle, or both.
To be able to receive SMS notifications, the respective user must have an associated mobile number. If this is not the case, contact your Perfecto administrator. For details, see Manage users.
-
For each option, select the relevant checkboxes depending on your preferences. You can receive notifications when a job run fails, is aborted, and is successful.
-
-
Under Recurrence, do the following:
-
Select the interval for the job execution (Once, Minutes, Hourly, Daily, or Weekly).
If you want to fine-tune your execution schedule, click Advanced to add a Cron expression. Cron expressions are helpful when you need to specify scheduling that cannot be defined using the other recurrence options. To create Cron expressions, you can use the Cron Expression Generator & Explainer.
The Cron expression is reset every round hour/day. For example, if a schedule is executed every 20 minutes starting 10 minutes after the top of the hour, in the first hour the script will run at x:30, x:50, and in the next hour it will run at x:30, x:50 again.
-
Select the start date and time for the job.
-
For the end date and time, select any one of the following options:
-
The end date and time
-
The number of executions
-
No end date
-
-
-
(Optional) For jobs with multiple tests, you can decide if a job stops after a test fails or continues running, ignoring the job failure. If you wish to continue the job execution regardless of the status of the test execution(s), select the Ignore failed executions checkbox.
-
Click CREATE.

-
Near the Perfecto logo, on the top toolbar, click Scheduler
and select View all scheduled jobs.
In this view, you can select individual rows by selecting the checkbox to the left of a row or select all rows by selecting the checkbox next to the header row. Then, you can carry out the available actions.
-
To sort the data of individual columns, click the column header.

-
In the Scheduled Jobs view, select the job you want to edit.
-
On the top toolbar, click Edit job.
Important: You cannot edit jobs created by a user who belongs to a different group you don't have access to. You can add tests to it and change the test execution sequence. The Use a single device for all tests in this job toggle stays unavailable. -
Make the required changes and click SAVE.

-
In the Scheduled Jobs view, select one or more jobs you want to delete.
-
On the top toolbar, click Delete.

-
In the Scheduled Jobs view, select one or more jobs you want to enable or disable.
-
On the top toolbar, click Enable or Disable.