I want to continue discussing some of the "Team Collaboration" features in the upcoming VSTS 2010 Architecture product. In this post, I want to show you how we are planning on providing you the ability to link *any* model element with any Work Item you currently have in your Team Foundation Server repository. The functionality that I'll be showing is not in any CTP or shipping product at this point, as it is new functionality coming in the VSTS 2010 Architecture product. Consider this a "sneak peek" of things to come. 😉
What's a Work Item?
For those of you who may not be familiar with the Work Item tracking capabilities built into Team Foundation Server, take a look at the walkthroughs found here. Think of a Work Item as a generic way to describe such things as Bugs, Requirements, etc. In fact, if you take the defaults while creating a new Team Project in TFS 2008, you'll see Bug, Quality of Service Requirement, Risk, Scenario, and Task work items.
You can create your own work item types, based on existing work item types ( extend the default Bug work item to add your own fields for example ), or completely from scratch. Take a look at this article for more details. An important new work item type coming in VSTS 2010 is a Test Case work item.
Work items can be linked together, or other artifacts can be linked to them. In the VSTS 2010 version of Team Foundation Server, rich support for hierarchical work items has been added. Check out Grant's post on this new capability.
You can query TFS, looking for particular work items, report on the links between work items, etc.
So let me show you what we have planned for you in regards to how you can link your various modeling artifacts to existing and / or new work items.
Associate to a Work Item
Here is a shot of an empty Class diagram.
Notice that in the bottom right corner, there is a property associated with the diagram itself called "Work Items", with a value of "0 associated", and it is greyed out. This is saying that this particular diagram is not associated with any Work Items.
Now, let's drop a new class, and look at its properties:
Same thing. No work items associated with this Class either.
This was a long winded way of saying that you can associate entire diagrams, as well as individual model elements, including link elements, to any type of work item supported by your particular Team Foundation Server and Team Project!
There are currently two ways to make a link between a diagram / model element and a work item. You can create the link implicitly while creating the work item, or you can link to an existing work item. I'll show you what both look like right now.
Create a Work Item
To create a new work item and automatically associate that work item to a diagram, simply right click in the background of the diagram and select "Create Work Item". Against a 2008 TFS Agile Team Project, here's what you would see by default:
Selecting "Bug" in the menu item above will do exactly what you'd expect. A new TFS Bug work item is displayed:
After giving the Bug a title and saving, you'll now notice that I have one Work Item associated with my diagram:
Link to existing Work Item
More likely, you will be linking diagrams and model elements to existing work items. Using our diagram from above, simply right click in the background of the diagram and select "Link to Work Item...". This results in the "Work Items Picker" dialog being displayed.
This dialog allows you to see lists of work items based on an existing query, a work item ID, or by title. You can further filter the query by a specific work item type.
I'm going to associate this diagram with a couple example Task work items by first using an existing query:
Selecting the "All Tasks" query and then clicking the "Find" button pulls back all the "Task" work items stored in TFS. I'm going to select the first two tasks, like so:
Clicking on the "OK" button and now I have 3 work items associated with the diagram.
View existing Work Items
Now that I have linked the diagram to 3 different work items, how do you easily view the specifics of those work items at a later time? Right click in the background of the diagram and select "View Work Items...". A new query results window will be displayed:
Everything I've just shown you in regards to associating the diagram with work items holds for model elements as well. Now when I say model element, I mean things like Classes, Associations, Dependencies, Attributes, Operations, Comments, Layers ( on the Layer diagram ) etc. Any and all of these elements can be associated with any type of Work Item.
Work Item to Models
So at any point, you can walk up to a diagram and understand what elements are associated with what work items. But what about the other way? Can you walk up to any work item and see the associated model elements? Yes.
I'd show it to you, but we don't have that quite up and running yet. 🙂
I've given you sneak peak at some new functionality coming in the VSTS 2010 Architecture product. You can create or link to existing work items to any UML or Layer diagram, and be able to quickly view the work items associated with those elements.
What do you think?
There are a number of scenarios that this functionality will enable, such as linking Use cases to Requirements ( especially now that we will have hierarchical work items in Rosario! ) to Test Cases.
Give it some thought. I'd love to hear how you would use this in your organization.