Reuse a test case

Do you already have a test case that fits a testing scenario you want to run again? Or do you want to reuse steps? There are a variety of different ways you can reuse part or all of a test case.

Here are the ways you can reuse a test case:

  • Call a test case: Add an existing test case as an embedded test step in other test cases.

  • Copy test cases: Copy and paste test cases or modules that contain test cases into the same project or a different project.

  • Copy test steps: Copy and paste test steps into any test case in your project.

You can also manage a central repository of test cases in the Test Design tab of one project and create test runs in the Test Execution tab of a different project. To learn how, take a look at Share test cases with another project.

Call a test case

When you're working in a test case, you may want to repeat a series of steps you've already created in a separate test case. To do this, you can use a called test case, which is an existing test case that you embed as a test step in another test case.

To call a test case, follow these steps:

  1. Navigate to the test case that you want to call a test case in. Note that you can't call a test case in itself.

  2. In the Test Steps section, select the checkbox next to the test step that you want to call a test step inside.

  3. Select the Action icon next to the test step you selected.

  4. Select the Test Cases option.

  5. From the Test Cases dialog, select the test case you want to insert, then select Add to call the test case.

The individual test steps inside the called test case don't display here, but the test step contains a link, which you can use to navigate to the called test case.

However, when you use a test case that contains a called test case to create and complete a test run, the TestPad displays the individual test steps of the called test case alongside the regular steps.

Copy a test case or a test case module

You can copy an individual test case or a module that contains multiple test cases in the same project or to a different project that you have access to.

To copy test cases, follow these steps:

  1. Select the project that you want to copy a test case or a module from.

  2. In the Test Design tree panel, select the test case or module that you want to copy.

  3. Right-click the selected test case or module and select Copy from the context menu.

  4. Navigate to the location you want to paste your selection to. This can be the same Test Design tab, or it can be the Test Design tab of a different project.

  5. In the Test Design tree panel, right-click where you want to paste the test case or module and select Paste from the context menu.

  6. Refresh the page to view the newly pasted items in the tree panel.

Copy test steps

You can copy test steps within the same test case or to a different test case in the same project.

To copy test steps, follow these steps:

  1. Select the checkboxes next to the test steps you want to copy. These can be consecutive or non-consecutive.

  2. Right-click one of the selected test steps and select Copy from the context menu.

  3. If you want to copy these test steps to a different test case, select that test case from the tree panel on the left. If you want to copy them to the same test case, stay where you're at.

  4. Right-click the destination row in the test case you want to copy the steps to and select Paste from the context menu. The copied test steps are added below the row you selected.