Monday, January 31, 2011

Team Foundation Server 2010 web access

You can access projects in Team Foundation server 2010 using web access.

There is no need for any client component to be installed in order to use web access.

URL: http://servername:8080/tfs/web/

Friday, January 28, 2011

"Microsoft.TestCaseCategory" not found while connecting to TFS

In order to work on VS2010 Test Professional, you need to have a TFS server configured and running. When we connect from VS 2010 Test Professional to a project in TFS 2010, there is no issue as all the categories are in sync. However, If you have installed VS 2010 Test Professional and you try to connect to a TFS 2010 server which is upgraded from TFS 2008, you will see the error below

NOTE: All variables that depend on your system are specified in red color and all constant values that you should enter specified in blue color.








You need to update certain values before you can connect to the project. And  to do this you need VS 2010 Professional or any other edition in order to get the latest category files.

Step1: Install Visual Studio 2010 Trial if you do not have Visual Studio 2010

Step2:  Connect to your TFS server from Visual Studio 2010 (since you cannot connect from VS Test Professional)












Step 3: Right Click on the default project collection node (not the project node!) and select Team Project Collection Settings --> Process Template Manager













Step 4: Select the process template your organisation is following (Cmmi or Agile). The "MSF for Agile Software Development V 5.0" is the default. Select the latest version 5.0 to get all the work items available. Version 4.0 has some workitems missing.















Step 5: Click 'Download' and specify location to save it. (The following commands are under the assumption that you have saved it in C:\) You willl see the following message.









Under C:\, you will see the folder MSF for Agile Software Development v5.0
 For convience, copy over the below files to C:\ (Makes it easier when running commands)

 a) All the files in C:\MSF for Agile Software Development v5.0\WorkItem Tracking\TypeDefinitions
 b) The categories.xml file in C:\MSF for Agile Software Development v5.0\WorkItem Tracking

Step 6:
Open the TestCase.xml file
Find the following and replace them correspondingly and save the file.
Original Value                   Expected Value
External Link Count           ExternalLinkCount 
Related Link Count           RelatedLinkCount
Hyperlink Count                 HyperlinkCount
Attached File Count          AttachedFileCount
Area ID                               AreaID


Open the SharedStep.xml file . Find the following and replace them correspondingly and save the file.
Original Value                   Expected Value
External Link Count           ExternalLinkCount 
Related Link Count           RelatedLinkCount
Hyperlink Count                 HyperlinkCount
Attached File Count          AttachedFileCount
Area ID                               AreaID

Iteration ID                         IterationID

Step 7: Open command prompt and change directory to the Visual Studio installation folder in your machine - C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE  




Step 8: Import Work Item definitions

C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE> witadmin importwitd /collection:http://servername:8080/tfs/CollectionName /p:projectname /f:"C:\UserStory.xml"

C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE> witadmin importwitd /collection:http://servername:8080/tfs/CollectionName /p:projectname /f:"C:\TestCase.xml"

C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE> witadmin importwitd /collection:http://servername:8080/tfs/CollectionName /p:projectname
/f:"C:\SharedStep.xml"

Step 9: Import Categories
C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE>   witadmin importcategor
ies /collection:http://
servername:8080/tfs/CollectionName /p:ProjectName /f:"C:\categories.xml"

Step 10: Disconnect from VS 2010 --> TFS, if you are connected.  Reconnect. You should now see all the work items








Once this is done, you will be able to connect from VS Test Professional 2010 to the TFS project.