If you are trying to connect Microsoft Test Manager to a Team Project that was created with TFS 2008, then you will very likely get this error: “The required category ‘Microsoft.TestCaseCategory’ does not exist in team project ‘[projectname]’”. This has to do with the workitem categories that are used by MTM. Basically, you group different workitem types into categories, which then allow MTM (and also TFS queries) to work with specific workitem types. The easiest way to get this fixed is to export the categories from a 2010 Team Project, and then import them to your team project:
>witadmin exportcategories /collection:http://MyTFS:8080/tfs/DefaultCollection /p:”Project1″ /f:”C:\temp\Categories.xml”
>witadmin importcategories /collection:http://MyTFS:8080/tfs/DefaultCollection /p:”Project2″ /f:”C:\temp\Categories.xml”
The file looks something like this:
xml version="1.0" encoding="utf-8"?> <cat:CATEGORIES xmlns:cat="http://schemas.microsoft.com/VisualStudio/2008/workitemtracking/categories"> <CATEGORY refname="Microsoft.BugCategory" name="Bug Category"> <DEFAULTWORKITEMTYPE name="Bug" /> CATEGORY> <CATEGORY refname="Microsoft.RequirementCategory" name="Requirement Category"> <DEFAULTWORKITEMTYPE name="User Story" /> CATEGORY> <CATEGORY refname="Microsoft.SharedStepCategory" name="Shared Step Category"> <DEFAULTWORKITEMTYPE name="Shared Steps" /> CATEGORY> <CATEGORY refname="Microsoft.TestCaseCategory" name="Test Case Category"> <DEFAULTWORKITEMTYPE name="Test Case" /> CATEGORY> cat:CATEGORIES>
Of course, you need to make sure that your team project has a “Share Steps” and “Test Case” workitem types defined, which you can also import from your 2010 project (witexport, witimport).