Back to QMetry All Products Help Page
Reuse Test Cases / Shareable Test Cases
Overview of Test Case Sharing
QMetry Test Management encourages users to maximize efficiency in managing tests. It provides different ways to reuse test cases, which saves the time of testers and makes information maintenance easier for testers. The following is a summary of the options that users can use in the same project.
Shareable Test Cases: Shareable Test cases are set of "Shareable Steps" that can be reused in other Test cases.
Copy Test Steps: Create a duplicate copy of step into the same test case. This is a one-time copy and paste of test steps.
Copy Test Cases: A one-time copy and paste of bulk test case(s). The test cases can be pasted into the same project and across projects.
Move Test Cases: The test cases can be moved into the same project and across projects.
Shareable Test Cases
QMetry allows users to create Shareable Test Cases that can be reused in other test cases as needed. A shareable test case is used in other test cases within the same project to reduce the effort of creating same test steps across test cases.
The shareable test case functionality is beneficial as it:
Saves Time: Common test steps are consolidated into a single shareable test case, eliminating the need to write them repeatedly in every test case.
Maintains Consistency: Update the shareable test case once to apply changes across all test cases that use it. All other test cases that use the common test steps can have the updated information by using the updated version of the shareable test case. Â
Create Shareable Test Cases
To create shareable test cases, navigate to:
Home > Test Case
After creating a test case, users can designate any or all of the steps within the test case as shareable.
Click on the test case entity key to open the test case details page
Go to the Test Steps tab.
Select the test steps to share.
Click on the Create Shareable Test Case button.
The Create Shareable Test Case button is available only on test case details page.
Â
The "Create Shareable Test Case" pop-up appears. Enter a summary or name for the shareable test case and click "Create." The shareable test case will then be generated.
Update Shareable Test Cases
Users can update a shareable test case at any time.
→ If updated with the same version, any changes to the steps will automatically reflect in all test cases using the shareable test case.
→ If updated with a new version, the latest version will be synced across all linked test cases. Users do not need to link the new version separately. All test cases that utilize the updated shareable test case will automatically incorporate the latest changes.
Steps to sync the latest version of a shareable test case in the test cases it is linked with.
Open the test case that uses a shareable test case in steps.
Go to the Steps tab on the test case details page.
Check the sync icon. If the shareable test case version is not synced, a refresh icon appears adjacent to the shareable test case.
Click on the refresh icon to sync the latest version of the shareable test case.
The shareable test case version is updated as per the latest version. Click Update to save the changes.
View Shareable Test Cases
To view shareable test cases in the project, check the "Show Only Shareable" box in the test case list view. This will filter the list to show only shareable test cases.
Shareable test cases are marked with a distinct icon.Â
To open the test case details page, click on the Entity Key of the shareable test case.
Reuse Shareable Test Cases
Shareable test cases are useful for reusing common test steps across multiple test cases. When creating a new test case, testers can incorporate a shareable test case if it includes the same steps needed.
Steps:
On the Test Case detail/create screen, go to the Test Steps section.
Click "Edit" to enable the '+' icon for adding steps.
To insert a shareable test case at the end, click the '+' sign and select "Insert Shareable Test Case."
To insert a shareable test case in the next row, click the cog icon on the test step and choose "Insert Shareable Test Case."
The "Link Shareable Test Case" pop-up will appear. Select the test case to link and choose a specific version if needed.
Click either "Link" to keep the window open or "Link & Close" to close the window after linking the test cases.
The shareable test cases are added to another test case. On the Steps tab, users can view the test case Key and version that has been linked.
Users can -
A. Drag & Drop test steps to re-arrange them.
B. Open the shareable test case in a separate tab.
View Test Cases Linked to a Shareable Test Case
On the shareable test case detail page, open the Test Case tab. The tab lists all the test cases in which the current shareable test case is linked.
Use Case:Â A shareable test case is updated, but testers do not know which test cases will be impacted due to this change. Hence, the Test Case tab is added to help testers see the test cases in which shareable test cases are used.
View Test Cases having Shareable Test Case
The Show Test Cases with Shareable Test Case filter is added to the test case tree to let users see test cases to which shareable test cases are linked it.
Use Case:Â Testers want a quick way to see test cases that contain shareable test cases linked to them. The filter allows users to get such a list of test cases promptly instead of checking individual test cases for the shareable test cases attached to them.
Easily Identify Steps from Shared Test Cases
On the Test Execution screen, users can view Shareable Step details. These steps are marked with an icon that opens them in a separate tab and shows the Entity Key when hovered over. During test execution, users can mark the entire test case as passed or failed, or update the status of each step individually.
Copying Test Steps
QMetry allows users to copy and paste test steps within the same test case.
Copy / Paste test steps within the same test case
Go to the Test Steps section and click Edit. The '+' icon and cog icon appears.
Select the test step to create a copy of.
Click on the Cog icon for the step and select Duplicate Row.
It will create a copy of the existing step and add it to the test steps.
Copy or Move Bulk Test Cases
Users can copy or move test cases within the same project or to another project. In case of bulk copy, the copied test cases will operate independently from the originals. Any changes made to the original test cases will not affect the copied ones.
Prerequisite: The destination project must have the same user-defined fields as the source project.
Test cases can be copied or moved to a specific folder or the root folder of the destination project.
What will be copied/moved with test assets?
Operation | Same Project | Across Project |
---|---|---|
Copy/Move | For the selected versions it will copy/move assets with all attachments, linkage of requirements, test cases, release, cycle, issues (linked with Requirement) | For the selected versions it will copy/move assets with all attachments.  |
To copy test cases from one project to another project or the same project, perform the following steps.
Select the project to copy a test case. Go to the Test Cases module, click on the Con icon, and select Bulk Operations.:
Step 1: Choose Operation: Select Copy/Move as the operation to perform and click Next.
Step 2: Select records
1. Select test case records that are to be copied/moved. To copy/move all the test cases across pages then select the Select All (Across Pages) option. Maximum 1000 records can be selected at a time.
2. Select test case version options:
Specific Version: Test Cases in the grid appear expandable when this option is selected. On expanding test case, users can view all the available versions for the test case.
All Versions: if this option is selected, then the Version button is disabled. Users can not select a particular version of the test case.
3. Click Next.
Step 3: Operation Details
Project: Users can copy/move test cases within the same project and across projects. Select the destination Project/folder path to copy the selected test cases to.
Owner: If the test cases are being copied to another project, then select the Owner of the test cases in the destination project. The Owner list is populated as per the Project.
Folder: Select the folder in to copy the selected test cases. The Destination Path is displayed according to the Folder selection.
Step 4: Click Copy/Move to get the confirmation message.
Test Data Parametrization in Shareable Test Cases
Users can create shareable test cases from steps with data parameters and insert these parameterized shareable test cases into existing test cases. During execution, the parameter values for the shareable test case will be sourced from the main test case using it.
Notes:
Users can insert shareable test cases with parameters into other test cases.
If a parameterized shareable test case, already linked to a test case and part of execution, is edited, it will be saved as a new version.
When copying or moving parameterized shareable test cases, any missing parameters in the destination project will be created.
Parameterized shareable test cases can be used across projects, with missing parameters created in the target project as needed.
Test cases with both parameterized and standard steps can be executed.
Shareable parameterized test cases linked to executions cannot be deleted.
Create shareable test case from parameterized steps
Open the test case which contains parameterized steps in it.
Select the parameterized steps to include in the shareable test case and click on the Create Shareable Test Case button.
Enter the name of the shareable test case and click Create.
On the test case list view, apply the filter to view only Shareable and the shareable test cases will be listed on the screen.
Open the shareable test case detail page. The shareable test case created from parameterized steps is displayed like below.
Inserting Parameterized Shareable Steps
Users can insert a parameterized shareable step from the current project as well as from other projects.
To insert parameterized shareable steps, follow these steps:
1. Open the test case detail page.
2. Go to the Steps tab.
3. Open the cog icon and click on the Insert Shareable Test Case.
On the Link Shareable Test Case pop-up, users can also insert a parameterized shareable test case from other projects. If the parameters of a parameterized shareable test case do not exist in the current project, then the parameters will get created in the project once the shareable test case is linked.
Select the shareable test case(s) to link and click Link.
The parameterized shareable test steps are linked to it.
Mapping Data Grid for Test Cases
To insert values in the parameterized shareable test steps, users need to map the data grid with the test case.
Steps
1. Link the main test case, which contains parameterized shareable steps, to a test suite.
2. Open the test suite details page.
3. Go to the Test Cases tab in the test suite.
4. Click on the Link Parameter Values sign @ to add values to the parameters for the test case which contains the shareable test steps.
The @ sign for parameterization is highlighted and has a hyperlink on it.
The Mapping DataGrid screen opens.
Choose a Data Source:
Select DataGrid: Choose this option to use a Data Grid from the Data Parameterization module. The drop-down will display all available Data Grids, and data will populate accordingly.
Fill Data Manually: Choose this option to enter parameter values manually. Map the values to the corresponding parameters.
Click "Save" to save the entered data.
Â
Execute Parameterized Test Cases
You can execute the parameterized shareable test steps. The values in the steps will get replaced as per the mapping of grid data for the test case.
Steps
1. Open the test suite detail page.
2. Open the Test Execution tab on it.
3. Click on the play icon to navigate to the Test Execution Screen to execute the parameterized test case.
On the Test Execution screen, clicking the "Expand All" button will expand test cases with parameterization to show Parameter Groups. The step count at the test case level displays as (number of test steps X number of data sets).
Expand each Parameter Combination to view the test steps.
The parameter values for shareable steps are shown according to the data grid mapping of the main test case. If normal steps have parameters, their values will also be updated based on the data grid mapping of the test case.
Â
Back to QMetry All Products Help Page