Checkin policy to make sure changesets are associated with Tasks - tfs

I am using Visual Studio Scrum process template and TFS 2013. Is there a way to define a checkin policy that would constraint developers to always use a Task item to associate with their changesets?
I have seen developers associated their changesets with PBI and Bugs without creating any Task items for those.

Yes, you could do it be defining a Work Item Query Policy.
Here is an example:
Create a new query like this (could be more advanced if needed)
Create the check-in policy and choose "Work Item Query Policy" and choose the query you have just made
If you now check-in you will get the warning that you haven't associated any items from that query - in this case, any tasks
I hope that was what you were looking for :)

Related

Modify Default Sprint Backlog Query

We've recently added a new workflow state "Released" to both our product backlog item (PBI) and bug templates. Unfortunately, when a PBI or bug is marked "Released" it no longer appears in our default sprint queries. Is there a way to change the default sprint queries so that this new workflow is included? We're using TFS 2015.
Any help would be greatly appreciated!
You cant modify the Query, but you don't need to.
You do need to add that new State to the Process Configuration so that TFS knows what to do with it. You need to mapp the new state to one of the meta-states; "Proposed", "InProgress", or "Completed".
https://www.visualstudio.com/en-gb/docs/work/reference/process-configuration-xml-element#map
Once you have added the map work items should appear on the relevant board.

Sprint work item default value

I need to set a default value for the Retrospective tab in TFS 2015.
Factory value is the following (TEXT 1):
What worked?
What didn't work?
What will we do differently?
Using the Powertools, I add a DEFAULT rule. In the rule i specify the following default value for the Retrospective (TEXT 2):
What worked?
Please check out what you wanted to do differently in the last two sprints.
What didn't work?
What will we do differently?
So really it's just adding Please check out what you wanted to do differently in the last two sprints.
Now here comes the problem. I save my work, and if I create a sprint in Visual Studio, TEXT 2 is displayed.
If I create a Sprint in Online TFS (accessed from browser), it will show TEXT 1.
Did anyone have a similar problem in the past?
Thank You in advance!
The Sprint work item, used in TFS 2010 with the MS Scrum 1.0 process template, was removed from the Scrum process template 2.0 of TFS 2012.
However since TFS 2012, you configure the sprint schedule as part of the new Agile Planning feature, making the Sprint work item redundant.
So your options for storing the goals\retrospective:
Use a Task work item (Title, Description fields)
Add custom field in the Product Backlog Item
Use SharePoint integration - store as a document

Integration of microsoft test manager with TFS for Bug management

Currently we are using TFS (Web Version) as we know a product backlog item can be added via 1-Product backlog Item 2-Bug (We are using Bug to keep track of Customer/partner logged bugs)
When ever we post a bug from MTM its visible in the product backlog list (Which we don't want)
Is there any alternates for this?
Can we create one more menu under the Backlogs tab?
enter image description here
You should really create a separate work item type, maybe "Issue", to represent an externally reported issue.
You can then triage those issues and break them down into Bugs and PBI's that then appear on the backlog for ordering.
Try and avoid the Bug as a task Anti-Pattern: https://nkdagility.com/avoid-bug-task-anti-pattern-tfs/
However you can also configure TFS to treat Bugs as Tasks, and thus they never apear on the board. Go to the Backlog and click the lower cog to configure this.
You an then create a custom "Issue" work item type for the reported stuff and add it to be shown on the Backlog.
You will need to edit the process template for this.

TFS 2010 Required Field Upon Check-In

My team is using TFS 2010 Agile template, and I wanted to enforce developers to fill out Completed & Remaining hours upon check-in.
Any way to make the two fields required upon check-in or somehow work this into TFS Check-In Policy?
You can write your own check-in policy:
http://blogs.msdn.com/b/jimlamb/archive/2010/03/31/how-to-implement-package-and-deploy-custom-check-in-policy-for-tfs-2010.aspx
or you can modify the state transitions in the work item template when the state changes.
http://msdn.microsoft.com/en-us/library/ms194981.aspx
If I had a way to go it would be the second way (and in fact I have done similar already at my work).

Merging all changesets associated with a WorkItem in Team Foundation Server

We're trailing the use of the built in bug tracking, and have written some integration into our helpdesk software that allows for escalation via workitems.
One thing I haven't found out how to do, is to merge all changes associated with a work item (say to go from dev branch to main) - I appreciate you can double click on a changeset in the merge dialog to view if it is associated with a workitem, and also that I can select individual changesets, and groups of adjacent changesets; but there doesn't appear to be any way to merge changes by workitem?
It is correct that you can't merge based on work items. It is probably not a good idea to do that anyway. It would be very difficult to make sure you get all the necessary changes needed for the main branch to build correctly. I would look into how you do your branching and a good starting point would be: Microsoft Team Foundation Server Branching Guidance
In TFS 2005 and 2008 the check in history will not be transferred between branches. You will get this in TFS 2010.
Merge changesets by workitem - https://tfsprod.codeplex.com/
Check out the ExtendedMerge feature.
Enjoy! :)

Resources