Rediger

Del via


Create and manage test suites

Azure DevOps Services | Azure DevOps Server | Azure DevOps Server 2022

Test suites organize test cases within a test plan. Use test suites to group related tests for a sprint, feature, or milestone. Azure Test Plans supports three types of test suites:

  • Static test suites — Manually organized containers that hold test cases and other test suites. Use them like folders to group related tests.
  • Requirement-based test suites — Automatically linked to a backlog work item (user story, PBI, requirement). Use them to track test coverage for specific requirements.
  • Query-based test suites — Dynamically populated by a work item query. Test cases matching the query are automatically included.

For key concepts, see Test objects and terms.

Prerequisites

Category Requirements
Project access Project member
Access levels At least Basic access to view test-related work items. Users with Stakeholder access can't access Azure Test Plans.

To add test plans and test suites, delete test artifacts, or define test configurations, you need Basic + Test Plans access or a Visual Studio subscription: Enterprise, Test Professional, or MSDN Platforms.
Permissions Area Path:
- Edit work items in this node: Add or modify test plans, test suites, test cases, or other test-based work items.
- Manage test plans: Modify test plan properties such as build and test settings.
- Manage test suites: Create and delete test suites, add and remove test cases from test suites, change test configurations, and move test suites.

Project-level:
- Manage test configurations and Manage test environments: Manage test configurations or test environments.
- Permanently delete work items: Permanently delete test-based work items.

For more information, see Manual test access and permissions.

Create a static test suite

  1. In your test plan, select More options for a test suite, and then select New Suite > Static suite.
  2. Enter a name for the suite.

You can drag and drop test suites to nest them under static suites, and drag test cases to reorder them.

Screenshot shows using drag and drop to move a test.

Add a requirement-based test suite

Add test suites for the backlog items that need manual tests. These tests can be user stories, requirements, or other work items based on your project.

Note

Requirement tracking is supported only for test cases linked through a Requirement-based test suite. Work items include a User Story (Agile), Product Backlog Item (Scrum), Requirement (CMMI), and Issue (Basic). The association between a requirement work item and manual test execution is only formed when the test case is linked by using a Requirement-based test suite.

  1. To add a suite to a test plan, select More options for the test suite, and then select New Suite > Requirement based suite.

    Screenshot shows creating a requirement-based test suite.

    Use requirement-based suites to group your test cases together. That way, you can track the testing status of a backlog item. Each test case that you add to a requirement-based test suite is automatically linked to the backlog item.

  2. In Create requirement-based suites, add one or more clauses to filter your work items by the iteration path for the sprint. Run the query to view the matching backlog items.

    Screenshot shows adding clauses to filter by iteration and running the query.

  3. In the list of work items returned by the query, select the backlog items you want to test in this sprint. Select Create suites to create a requirement-based suite for each one.

    Screenshot shows adding requirement-based suites for your backlog items.

Create a query-based test suite

  1. In your test plan, select More options for a test suite, and then select New Suite > Query based suite.
  2. Define the query to match the test cases you want. For example, filter by area path, iteration, or state.
  3. Select Create suite. Test cases that match the query are automatically included and stay in sync as work items change.

Note

Query-based suites are read-only. You can't manually add or remove test cases. To change the suite contents, update the query.

Track test suite changes

You can track changes to test plans and test suites. Open the work item for the test plan or test suite, and then view the work item history.

For test suites, the Test Suite Audit entry under the test suite history tracks other actions such as:

  • Adding or removing test cases from a test suite
  • Adding or removing testers from a test suite

Find a test suite in a test plan

To find a test suite within a test plan, select the filter icon in Test Plans. Enter the test suite name to filter the list. Search results are limited to the selected test plan hierarchy.

Screenshot shows finding a test suite in a test plan.

Next step