Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

QAS provides Shareable Test Case feature that fulfills the purpose of test case reusability when a set of similar steps are used in multiple test cases . Users can create a sharable test case for common test steps. This test case is then shared and reused in more than one parent test cases. It saves testers' efforts and time that is consumed in adding repetitive steps into multiple test cases.

...

You can see the selected steps are appended to the existing shared test case.

...

View the details of Shared Steps

A quick-access button called ‘Step Details’ is available on the Test Case, clicking on this button users can view the shareable test case step details with its latest execution status in a new tab. This feature is only available for those shareable test cases in which Test Data is not attached.

...

Users can view the last execution detail of the shareable test case.

...

Use Shareable Test Cases

1. Create a test case and record its initial step.

...

Then use this shared test step in test cases.

...

Change/Export Shareable Properties

Users can edit exported properties of a shareable test case.

1. To change properties of a shareable test case, first export the properties by clicking on the Shareable folder and selecting Export Properties button on it. Changes made on exported properties will be applicable at Project level.

...

2. There are two options to export the properties:

  • Inline Shared Single File: Shareable Test Case will be automatically converted to inline code in the same file in Code View.

...

Open the test case in which the shareable case is used and click on the Code button.

...

  • Reference Shared Multifile: Shareable Test Case file will be generated separately and commented line will be shown as reference at the place of shareable test cases in Code View.

...

Open the test case in which the shareable test cases are used and click on the Code button.

...

Export Shareable Cases for CI/CD Execution

After updating shareable properties (inline/shared), click on Export to generate code for the CI/CD execution.

  • If Inline Shared Single File is selected for shareable properties: Shareable Steps will be automatically converted to inline code in same file in Code View.

...

...

Execute shareable test cases by providing test data parameters directly at input level

Users can manage Test Data variables for shareable test cases at an individual test case level where the test case is reused. Irrespective of the original variables which are used in the shareable steps, users can use new test data variables in the reused shareable test case. The sequence of variables is considered while mapping the data.

For example,

A shareable test case ST1 is already in use in a test case which is using a Test Data TD1. Now the Test Data for the test case is changed to TD2 and so the corresponding variables for the test case are also changed.

In this scenario, users can still use the associated shareable test case ST1 by replacing the earlier variables with the different variables of the new test data TD2.

Note: Make sure the sequence of the variables is maintained to map them with the variables in the attached test data set.

The variables are mentioned within curly braces { }.

Info

Syntax to mention the variables: ${variable1},${variable2}

...

Export Shareable Test Cases

Shareable test cases can be exported as custom methods in source code. Users can obtain the reference of the shared Test Case in a .bdd feature file by exporting the code of a test case in which a shareable test case is used.

Steps

1. Click on the more menu for the test case and select Export.

...

The next screen shows the location where the code will be exported.

2. Click Export to proceed.

...

For better accessibility, users can directly go to the definition of a shareable test case from a .bdd file by right-clicking on the respective line and then selecting ‘Go to Definition’. It opens the code of shareable test case in a separate tab.

...

Shareable Test Case is mentioned as a custom method in the source code of shareable test case’s definition.

...