Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

[Ship It!] Requirements traceability

 
Jason Menard
Sheriff
Posts: 6450
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where do you guys stand on requirements traceability? This is another one of those big CMM things. It's also something that can cause a lot of pain for the individual developer, as quite often what is being looked for is a way to tie project artifacta (design diagrams, code, etc...) back to a requirement, keeping in mind of course that some artifacts are architectural and do not address specific requirements. That said, I haven't seen any painless way to really implement this that a developer can latch onto without wanting to pull his hair out.

I've been thinking that it might be fairly painless to annotate the requirements addressed by a class or method in comments, and then use a tool like XDoclet or even simple text processing to run against the code base to produce a report detailing what code is affected by a change in a given requirement, for example.

What have you guys seen as far as handling requirements traceability?
 
Jared Richardson
author
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you order your work via The List and The List is populated via your bug tracking or feature tracking software, you can link your specific List items back to an entry in the bug or feature software. The bug or feature tracking software allows for lots of detail on who requested an item, who's edited the request over time, etc.

You can also reference a bug number or feature request number in your source code checkin comments. The number can used to look up the issue in the tracking software. You can even past in a link for some systems.

Given how many different requirements might drive a given class or routine over time, I'd be inclined to keep that information out of the code and in the source code management system.
 
Ilja Preuss
author
Sheriff
Posts: 14112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you just want to know what requirements a certain line of code is needed for, you could just delete that line (temporarily) and observe what acceptance tests fail...
 
Jared Richardson
author
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Ilja Preuss:
If you just want to know what requirements a certain line of code is needed for, you could just delete that line (temporarily) and observe what acceptance tests fail...


LOL!
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24208
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As someone who does agile development, but is familiar with how a number of shops do rigorous requirements traceability, the thing that's always astonished me is that 99% of the time, what they actually do is trace requirements to design/architecture artifacts. They do not trace requirements to real code, or least of all to executable tests.

We do semi-formal traceability to tests on one project I'm on: if you point to a story on our "done" list, I can tell you which tests prove that story is done and works, and I can tell you which "bullet" in a requirements document inspired that story. This is something that most XP shops would be able to do with a minimum of effort. We have never found it useful in any way, but we wanted to see if it could be done.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34095
337
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jason,
What do you do for requirements traceablility now? We're getting started with CMM. For now, we're just documenting that the requirement is in a certain release though. For major requirements we estimate and track time per really high level requirement, but it's not tied to the code in any way.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic