Your Ad Here

Tuesday, February 16, 2010

Traceability Matrix: How to Map Requirements to Test Cases

Refer to following articles for more:
When you write test cases from a requirement document or use case document, you should remain sensitive towards the coverage of the requirement and converting them to testable items. The test cases are designed keeping in mind about the requirements coverage. If there are areas not covered in the test case, it will go untested. In order to verify whether all the requirements are being tested or not, Traceability Matrix is created. It maps requirements to the test cases.

So, what is the format?

If you have a tool to trace the requirements, fine. Otherwise, traceability matrix can be maintained in a Word document or a Spreadsheet. In the tool, each use cases or requirements are linked in one-to-many relations with the test cases.


In the Spreadsheet, the format of a traceability matrix is a table -- having columns as the requirement id (or use case id) and rows as the test case id. Please refer to the picture below.


Alternatively, traceability matrix can be created in following format in Word document:



And, why is traceability matrix important?

Traceability is important for the successful coverage of requirements in the test cases. Besides, it helps in following:

- Knowing whether whole of the current requirements are considered for testing
- Knowing whether changed requirements are converted into testable items
- Documentation to form the basis of testing
- Understanding where requirements have been built into the system
- Forming the basis for ongoing system documentation

To conclude, writing a traceability matrix is not a one time affair. It should be updated with every change in the requirements to avoid any potential threat of requirement items going untested.

No comments:

Post a Comment