You can enable traceability from Selenium tests to work items in your application lifecycle management (ALM) system and report the data to Parasoft DTP. This provides visibility into how well software requirements are covered by tests. In this section:
Initial Set Up
- Verify that Selenic can send results to DTP. See Reporting Results to DTP.
- Verify that DTP is integrated with a supported ALM. Refer to the Parasoft DTP documentation for details.
- Create work items (e.g., user stories, tasks, tests, etc.) in your ALM. Refer to your ALM documentation or ALM administrator for details.
- Test traceability is enabled by annotating your Selenium tests with tags that correlate them with a work item in your ALM. To use annotations, the Parasoft Annotations Maven dependency must be added to your project. The dependency is included when creating projects with Selenic (see Creating Selenium Test Projects from Recorded Actions). For existing projects, add the dependency to your project pom.xml file:
You can also refer to the Parasoft Annotations project on GitHub, which includes the JavaDoc API documentation.
@WorkItem annotation in your test methods and classes to correlate the test with work items in your ALM. Annotations include the ID of the work item, type of work item, and a URL to the work item in the ALM (optional). The following table describes
Specifies the type of work item in the ALM to associate with the test. Valid values:
Specifies the ID of the work item in the ALM. The type and number of characters vary acrosss ALMs.
Specifies the URL of the work item in the ALM. The purpose of the URL parameter is to provide additional information for test reviewers. It is not used for any Selenic functionality.
Execute your tests with Selenic after adding
- See the Analyzing Test Executions and Generating Recommendations section for instructions on executing tests in the IDE.
- See the Command Line section for instructions on executing tests on the command line.
The annotations will be included in the test results sent to DTP where they can be processed and included in DTP's reporting mechanisms.
Refer to the Parasoft DTP documentation for information about viewing test data in DTP dashboards and widgets.