Friday, November 27, 2009

Earlier this week at the Omaha Team System User Group someone asked about how to add new statuses to a work item in TFS.   I mentioned I had the steps documented that I would send him.  After reviewing the steps I thought it would be useful if I posted this for everyone. 

Download and Install the TFS Power Tools

Unless you prefer editing XML and running command line utilities to GUI editing, the first thing you should do is download the latest edition of TFS Power Tools.  The Power Tools are a must have Team Foundation Server add-on that Microsoft has used to add functionality since the release of TFS Power Tools.  There has been several updates with October 2008 being the latest release.

Download Visual Studio Team System 2008 Team Foundation Server Power Tools - October 2008 Release

Work Item Template Process Editor

After the TFS Power Tools are installed,  Process Editor is now available under the Tools menu item.

image

 

Opening a Work Item Template for One Team Project

To edit a Work Item Template (WIT) there are a couple options.  To modify the template for one project, you can open the WIT directly from the project, edit it, and save it back to that project by choosing the “Open WIT from Server” option.
When you choose “Open WIT from Server”, it will display a dialog with all of the team projects and the templates.  In this example, the Bug WIT from the SampleScrum template is chosen.

image

 

Opening a Work Item Template for Multiple Team Projects

To edit a WIT for multiple team projects, you will want to export the template to a file, edit the changes and then import that change into each of the team projects.
To Export the WIT, choose Export WIT.   This displays the dialog to select the WIT.

image

Save the WIT to a location on your local machine.

image

It will prompt you if you would like to include the Global List definition.  You can choose No.
Next open the saved WIT by choosing “Open WIT from File” and selecting the saved file (Bug.xml). 

 

Editing the Work Item Template

The Work Item Template Editor has three tabs.  In this example we don’t change any of the fields or the layout of the work item, so we can ignore these tabs.

image

To add statuses to the Work Item, we will modify the Workflow tab.  Adding a status is more than just adding the option to a list.  The statuses of a work item are part of the workflow.  Basically each status is only available when it is enabled in the workflow.  For example, you might have a “Fixed” status and a “In Test” status.  In the workflow, you can define it so that “In Test” won’t be available to select until it has been marked “Fixed” first.

Here is an example of the workflow tab

image

The different Statuses in Red and the arrows show the flow of one status to the next.   Once it is decided when the new statuses will appear and what statuses will be available after the new status, we can add the statuses and connect them to the other statuses.

Add a Status by selecting the State item in the Toolbox  (if the Toolbox is not visible, choose View -> Toolbox from the menu.

image

Drag the State item to the canvas in an area where it will be easier to connect it to the other States.  If the workflow becomes cluttered, you can right click on it and choose “Reset Layout”

image

When you have added the status to the canvas it will look similar to this

image 

Give the status a name by typing over the State1 text

image

Now, connect this to the previous status.  For this example the bug will go from “In Progress” to “Fixed” to “Ready For Test”.  Do this by clicking on the Transaction Link from the Toolbox, this will change your cursor to the link cursor.  Click and hold on the starting Status and drag the line to the target Status.  This will add the line between the two and create a Transition box.

image

For the new status to be valid, you must give the Transition a Reason.  This is just a textual explanation why it would move to this status from the previous.  Expand the Transition box so it shows the Reasons, Actions, and Fields.  Right click on the box and choose “Open Details”.  A Workflow Transition dialog box will display.  Choose the Reasons tab and modify the Value to display the text you would like.

image

Add a second Transaction Link from the new status (Fixed) to the Target status (Ready for Retest) and give it a reason.
Once this is added, you can validate your workflow by right clicking on the canvas and choosing “Validate All”.

image

If there are any errors in the validation they will be displayed in the Error List.

image

If there are no errors the Output tab will look similar to this

image

Click the save button in the toolbar to save the WIT.   If you have opened the WIT from the server then this saves it back to the Team Project and is available.  If this was a File then you must import it into the appropriate Team Project(s).
To Import the Work Item Template, choose “Import WIT” from the menu.  This dialog will display.  Select the file that was edited (Bug.xml) and then select the team project and click OK.

image

Repeat to add to the other Team Projects.

 

Applying Change to Process Template


Now that the work item is modified, if you want this change to be in new projects created you must update the source and re-upload the templates.
Copy the bug.xml and bug.wit to the source template folder on the TFS Server.  The Default location is
C:\Program Files\Conchango\Scrum for Team System\ProcessTemplate\AgileSoftwareDevelopmentwithScrum\WorkItemTracking\TypeDefinitions

image

To upload the template, right click on the TFS root node in the Team Explorer and choose “Process Template Manager”.

image

A dialog will display that contains a list of the installed templates.  Click on the Upload and browse to:
C:\Program Files\Conchango\Scrum for Team System\ProcessTemplate\AgileSoftwareDevelopmentwithScrum
Open the ProcessTemplate.xml file.

It will next prompt you if you want to overwrite. Choose Yes and it will upload the changes. If you do not wish to overwrite it, then you must change the name by opening the same ProcessTemplate.xml with the Process Editor.

image

 

That completes the steps to modify the Work Item Templates, apply the changes to one or multiple team projects, and also back to the template for future projects created with the the process template.

Mike

Friday, November 27, 2009 10:56:00 AM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
Thursday, November 26, 2009

Here are the updated slides for my Getting Agile with TFS 2010 presentation.  I gave this presentation for two lunch and learns at ANT and then earlier this week at the Omaha Team System User Group meeting.  I had a great time giving this presentation multiple times.   Thanks everyone that attended these talks. 

Getting Agile with TFS 2010 Presentation Slides

Mike

 

Thursday, November 26, 2009 11:54:00 PM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 
Tuesday, November 03, 2009

I am going to giving two Getting Agile with Team Foundation Server 2010 talks in November, both in Omaha, NE.  On Thursday November 12th, I will be giving the talk for a lunch and learn at Advanced Network Technologies.  You can register for the event here.  On November 24th, I will be giving the talk at the Omaha Team System User Group Meeting.  Here is more information about the event and registration instructions.

This is the same talk as the one I gave at the Heartland Developer Conference in October but I will be using Beta 2 for these two.  Here’s some more details on the presentation and myself.  I look forward to seeing everyone there.

Presentation: Getting Agile with TFS 2010

This presentation will demonstrate a complete two week scrum iteration from the planning meeting to development, testing, and bug fixing to deployment utilizing the features found in Team Foundation Server 2010. New features include gated check-ins for Continuous Integration (CI), Test-Driven Development (TDD), Product Backlog enhancements including hierarchical views and support for multiple teams to work from a single backlog. The presentation also demonstrates the enhancements to the TFS Portal and Web Access to support Agile planning and displaying graphs such as burn-down charts. Each walk through includes a live demonstration of the feature in Visual Studio 2010.

Speaker: Mike Douglas, Deliveron Consulting Services

Mike Douglas is a Solution Consultant at Deliveron Consulting Services where he provides end-to-end solutions and TFS installation, configuration, and custom development for clients.  He has over 11 years experience building enterprise level applications on a variety of .NET technologies including WCF, Web Services, ASP.NET, Disconnected Smart Clients and Data Synchronization, BizTalk, and Team Foundation Server.  Mike enjoys trying to keep up with the constant change and evolution of .NET.  Mike is an experienced presenter having spoken at several Omaha .NET User Group meetings on CSLA.NET, Subsonic, and TFS.  He also spoke at the 2008 ESRI International User Conference on a GIS integration project he helped lead. Mike actively maintains the open source project, Team Deploy, on CodePlex for deploying MSIs using Team Foundation Server.  Mike also enjoys sharing his experiences in Code Generation, CSLA.NET, and TFS on his blog at www.CodeSmartNotHard.com.

Tuesday, November 03, 2009 3:42:00 AM (Central Standard Time, UTC-06:00)  #    Comments [0]  | 

Theme design by Jelle Druyts

Pick a theme: