With TFS 2010 it was already a common practice to create security groups as subgroups of the Contributors group to define teams. When you upgrade a Team Project Collection with such a setup to 2012, there is no way to convert these existing semi-teams to fully supported 2012 teams out of the box.
It turns out that you only need to apply a few small changes to the security group to have it upgraded.
Connect to TFS and retrieve the group:
collection = TfsTeamProjectCollectionFactory.GetTeamProjectCollection(new Uri(collectionUri)); collection.EnsureAuthenticated(); var identityManagementService = collection.GetService<IIdentityManagementService2>(); var securityIdentity = identityManagementService.ReadIdentity(group);
Set the team property and save it:
securityIdentity.SetProperty(IdentityPropertyScope.Local, "Microsoft.TeamFoundation.Team", (object) true); identityManagementService.UpdateExtendedProperties(securityIdentity);
I'll probably end up submitting this as another patch to the TFS Team Tools project.