Sharing Test Cases

Zephyr allows users to share test cases across multiple projects and test repositories. You can share test cases from releases to other projects in the system, and from the global test repository.

For example, while working on a release, you can share test cases in the global test repository, so there is no need to rewrite them from scratch.

Best Practices

Test case sharing allows users to use various test repositories and reuse test cases across all projects and releases to maximize the efficiency of their testing activities by reducing the time spent on writing like test cases. Users can simply create test cases that are default templates and share those test cases, which can be used in different projects or releases. For example, a test manager can create a test case to be used as a template in the global test repository. The testers working in their project can reuse the test case in their releases.

Share test cases

To share a test case, perform the following steps:

  1. Click the button below on the folder you want to share a test case with:

    ZE_Screenshot_ShareTC_07.png
  2. Click Share Testcases:

    ZE_Screenshot_ShareTC_01.png

    A dialog will open with your local test repository on the left and other available test repositories on the right:

    ZE_Screenshot_ShareTC_02.png
  3. Navigate through the available test repositories on the right, select the test case you need, and drag it to the destination folder in your test repository. Select the Enable Drag and Drop Notifications checkbox in the Miscellaneous dialog box to enable drag and drop notifications. For more information, refer to Advanced the section.

    The drag-and-drop notification appears whenever test cases or folders are moved, copied, or shared across different levels. This includes actions such as:

    • Moving items from the Project Test Case Repository level to the Release level.

    • Moving items in the Release level.

    • Moving items in the Import level.

    • Moving items from the Import level to the Project Test Case Repository level.

    • Moving items from the Import level to the Release level.

    ZE_Screenshot_ShareTC_03.png

    The shared test case will appear on the left of your current test repository.

    ZE_Screenshot_ShareTC_04.png

    Now, when you close the Share Testcases dialog, you will see the shared test case in your current release's list of test cases.

    ZE_Screenshot_ShareTC_05.png

    Important

    In the Share Testcases dialog, you can also search for test cases you want to share. To do that, switch to the Search tab, specify the project and release from which you want to share test cases, enter a ZQL query, and click Go.

    ZE_Screenshot_ShareTC_06.png

Map shared test cases.

If a shared test case is mapped to a requirement in another release and you want it to be mapped to that requirement in your current release, there is no need to map it from scratch. You can map it automatically by adding the required information to your current release. Here is how you can do that.

Suppose you have  Release 1.0  with the test case “ test 1 ” mapped to the “ Req1 ” requirement, and have shared the test case with the above. You also want to map the test case to  Req1  in  Release 2.0.

  1. Navigate to Requirements , and in the Project Requirements repository, select the folder containing the requirements of the needed release (in our case, Release 1.0).

    ZE_Screenshot_MapSharedTCs_01.png
  2. Select the requirement to which the shared test case is mapped in Release 1.0 and click Allocate to add the requirement to your current release (Release 2.0 in our example).

    ZE_Screenshot_MapSharedTCs_02.png

    The requirement will appear among the requirements of your current release and will be automatically mapped to the shared test case.

    ZE_Screenshot_MapSharedTCs_03.png

    If you switch to the Test Repositorynow, you will see that the shared test case is mapped to the requirement.

    ZE_Screenshot_MapSharedTCs_04.png

    Note

    Deleting a requirement or test case removes the mapping as well.

Additional Notes

There are two ways to share test cases from the global test repository.

  • You can share single or multiple test cases: select the needed test cases and drag and drop them to your test repository.

  • You can share an entire folder of test cases: select a folder and drag and drop it to your test repository.

The IDs of the shared test cases will remain the same. Users can distinguish shared test cases from the other ones in the test repository by the italicized test case name.

Publication date: