Reuse an Existing Test Case as a Prerequisite in New Automated Tests Avoid repeating the same setup steps in every test. Instead, reuse essential flows—like your login test case—as prerequisites. This
Go to the Test Development section.
Image
Click the pencil icon to view your existing test cases.
Image
Make sure the login test case (or any prerequisite you want to use) is set to Ready status. Only ready test cases can be used as prerequisites.
Step 4: Click the plus (+) icon to start creating a new test case.
Image
Choose Start with AI Assistance to begin building your new test.
Step 6: In the prerequisite selection section, search for your existing login test case.
Image
Select the login test case (e.g., SWAG Labs login) as your prerequisite.
Add additional steps needed for your new test case.
Click Create Generate Test Case to save your new test.
Image
Click Generate Test Case to generate and run the test.
Image
Start execution. The system will run the login prerequisite test case first, then continue with the remaining steps in your new test.
Image
Image
Now, anytime you need to update the login flow, just update the original test case. All tests using it as a prerequisite will automatically run the updated steps. This keeps your test automation suite clean, modular, and scalable.