Automation trending in today’s fast-paced IT world. More importantly, it’s essential for projects that require testing support for a long duration. When there is a need for continuous delivery and testing, it helps the tester compare actual outcomes with expected outcomes. Involving automation in these projects reduces repetitive manual work and saves time, effort, and cost of testing the application, making for a productive Worker Experience.
To perform automation on an application, the automation engineer should have in-depth knowledge of the business flow that needs to be automated — this is where automatable test cases come into play.
Automatable test cases give a detailed, step-by-step description of the business flow that has been considered for the automation. However, sometimes the automation engineer needs to predict the expected outcome of the test case. Therefore, infestation of proper detailing at each test step is required to make a test case more effective.
How to decide whether a test case is automatable?
- Repetitive testing scenarios that run for multiple sandboxes.
- Multiple execution of test cases. i.e., performing regression or sanity testing.
- Test cases with multiple/large data setups that are prone to human error during the execution.
- Time consuming test cases requiring a lot of effort when tested manually.
- Browser-specific test scenarios.
Guidelines for writing an effective automatable test case
- Pre-requisite data should be specified.
- Test case should not leave any judgement on the automation tester.
- The test data should be specified at each applicable test step.
- Notes can be added at each test step for more clarity.
- The test case should be written in proper execution order with all the mandatory steps.
- Expected results should be mentioned at each test step.
Approach to write automatable test cases in CMC
- Test case name - Test case name should start with prefix “<Automation>”, to distinguish between manual and automation test cases. This is what the implementation should look like in CMC:
- Filter automatable test case - The identification of automatable test case can be done with the help of “Automatable Test?” checkbox, which is present on the “Test Case” in CMC. It determines whether a test case is automatable or not. If the test case is automatable, it should be marked as true. User can create “Reports” in CMC for filtering the automatable test case out of all the manual test cases present in a test suite.
- Description (test step) - The detailed description on each test step should convey the objective of the test case with pertinent information such as the test environment, profiles, and other crucial information.
A test step represents each step that needs to be executed in order to complete the flow of execution. It should be clear and concise, providing information on how to execute the test case without skipping any necessary details. This is what the implementation should look like in CMC:
- Test data - The tester should include any preconditions that need to be met prior to the test step execution. This information includes browser, test environment, and any setup required before running the test step. This is what the implementation should look like in CMC:
- Expected results - The expected results should convey the expected outcome of the test script execution, corresponding to each test step. According to the actual outcome of the test script execution, the test case is determined to be “pass” or “fail”. This is what the implementation should look like in CMC:
A sample test case
Title: <Automation> Verify that user can login at www.outlook.com.
Description: A registered user should be able to successfully login at www.outlook.com web application.
Similarly, following the above guidelines, effective automatable test cases should be created to ensure efficiency, quality, and cost.
Do you want to learn more about how cutting-edge companies use technology? Check out our Appirio Hub, full of other technical and Worker Experience resources.