Traceability – A generic way to link requirements and test cases

Do you want to establish (requirements) traceability to your custom scripts, text files and tools, e.g. link requirements residing in DOORS or Polarion to test cases defined in tools such as VectorCAST or maybe to a custom scripting language?
In this post I want to illustrate how to achieve not only the linking in such a case, but also how easy it is to navigate such links and to create a coverage report based on those links. I will use the next generation Text Adapter of YAKINDU Traceability (YT) which is our feature of the month for Feb. 2018.

To keep things simple, I will use an existing example, namely the traffic light example project of YAKINDU Statechart Tools, which comes with so-called SCTUnit as a textual language for tests. This example specifies a simple statechart for a traffic light combined with pedestrian lights. I augmented the palette of work products shipped with the example by setting up a simple requirements specification in MS Word (you may note that I’m not an urban planner or a  traffic lights expert. This is just an illustration).

requirements-specification-yakindu-traceability


I configured YAKINDU Traceability to recognize these requirements and the test methods specified in the SCTUnit text files shipped with the example. The following animation shows how easy it is to create links by a simple drag and drop operation. More precise, it shows how requirement
REQ3 gets linked to the tests testYellowOffAfter500ms and testYellowOnAfter1s.

VerlinkenDND

You may notice that YAKINDU Traceability creates comments in the test scripts. These comments are the links, i.e. in this example YT is configured to use the SCTUnit files as persistent storage. This approach guarantees consistency of test cases and links with regards to version control. For the actual traceability link, the ID of the requirement is sufficient. For additional convenience, I configured YT to not only put the ID into the comment, but also the requirements name and even the description.

Once a traceability link is established, you may use it as a hyperlink. The only thing you have to do to activate hyperlinking is to press the CTRL button on your keyboard.

The following animation illustrates how to navigate from the test script to the requirement in Word.

NavigationPerHyperlink


Last not least, I want to give just one example how traceability can be analyzed to e.g. create a test coverage report. To keep things simple, I utilized YAKINDU Traceability's built-in query engine for that,
 which is designed for fast ad-hoc queries. (For more advanced analysis and reporting, YT comes also with a built-in reporting engine. Or you can connect it to your data warehouse.) The screenshot below shows in the lower right corner that 100 % of our requirements are covered by at least one test (which is admitted not too hard to implement if you have only 5 requirements).

TestCoverageSummary


If you want to get hands on YAKINDU Traceability yourself, just click on the button below and feel free to download our example showcase which demonstrates a traceability scenario consisting of various artifact types that are typical in a software development setting.

New Call-to-action

About Boris Holzer

I've been working as (technical) project manager in several business domains. I like the power of language engineering and every other application that makes development easier and improves quality. Since 2014, I'm in charge of YAKINDU Traceability.