Task 2: Record, Replay and Run a Test Case
IDA provides a browser plugin recorder, which allows users to record their test scenarios without coding.
About this task
In this task, you can record, replay and run a test case that you generated in the previous task.
Prerequisites
- IDA is up and running.
- BAW Process Center is up and running.
- Selenium Hub is up and running.
Step 1: Set Up Testing Environment
As a developer, you need to set up your testing environment first.
Procedure
-
Install IDA browser plugin according to Doc. Click the plugin icon on your browser extension toolbar, enter the IDA web URL and click Sign In to sign into the plugin.
-
After you have successfully signed into the plugin, clicking Home will open another browser tab of the IDA web homepage.
Step 2: Set up assignees for case steps
In this step, you need to assign the Workflow task users for case steps. Take the case1 of Create Position Request CSHS as an example.
Procedure
To set up assignees for case steps:
-
Click Create Position Request CSHS in the left-side menu bar.
-
Click case1.
-
Click the Edit button on the right top of this page.
-
Move your mouse to the first row of the case steps, right-click your mouse and click the Edit button to edit this case step.
-
Select celladmin in the Assignee field in order to specify other Workflow users to help you complete the business process. Click the Save button to finish editing this case step.
-
Click the Exit Edit button on the right top of this page to finish editing the test case.
Step 3: Record a test case
In this step, you can record some case steps according to your inputs on the web UI.
Procedure
To record a test case:
-
Click the Edit button on the right top of the page.
-
Click the Record button on the right top of the page.
-
The IDA Recorder window pops up. Click the Run icon to start recording.
When you first record and play your test case, you might see the below error.
Solve this issue according to Doc.
-
Step 1 is executed, and once it is completed, the human service is shown.
-
Then the recorder comes to step 2: the Debug {{log}} step. Due to the debug purpose, the recording is pending at this step. You can perform some actions on the human service, and IDA recorder will record every UI action.
-
In the Submit position request human service, change Employment type to Full-time, Department to Marketing, Location to Boston. As you can see, these three web operation steps are captured in the IDA Recorder as test case steps.
-
Click the button to finish the recording. You can see the recorded case steps in the list table.
Step 4: Replay a test case
In this step, you can replay a test case that you recorded in the previous step.
Procedure
To replay a test case:
-
Click the Record button on the right of the case name to replay it.
-
Click the Run icon on the IDA recorder to start the replay.
Step 5: Run a test case
In this step, you can run a test case. The running of automated testing is asynchronous.
Procedure
To run a test case:
-
Click the Selenium Hub button on the right of the Edit button.
-
When it is finished, go to the Test Report section to see the detailed report, including the process execution flow.
-
Check every case step result status with PASSED or FAILED in the case step list table.
-
Click the Screenshots icon link to see the captured screenshot.
Step 6: Stop a test case
In this step, you can stop a test case.
Procedure
When the test case is running, click the Stop button on the right of the case name.