Category Archives: 11561

Building a Release Pipeline with Team Foundation Server 2012

Last week Microsoft Patterns & Practices released a new guide about release management using TFS 2012. I had the opportunity to read the guide during development and it has both great guidance, hands-on labs and concrete tooling to support the process. I personally really liked the section on getting good feedback, where the authors shares some good examples on how to use TFS to understand and optimize cycle times in the release process. I definitely recommend taking a look at this guide if you in any way are involved in the software release process.

From the guide:

“The goal of this guidance is to put you on the road toward continuous delivery. By continuous delivery, we mean that through techniques such as versioning, continuous integration, automation, and environment management, you will be able to decrease the time between when you first have an idea and when that idea is realized as software that’s in production. Any software that has successfully gone through your release process will be software that is production ready, and you can give it to customers whenever your business demands dictate. We also hope to show that there are practical business reasons that justify every improvement you want to make. A better release process makes economic sense by providing:

  • Faster time to market
  • Better quality software
  • More productive employees

Follow the team at Trey Research as they refine their processes and move from a mostly manual pipeline to one that’s mostly automated.”

Start reading the guide here.

Extending TFS Work Item using a web page and the WebpageControl

Have you ever wanted to add custom behavior to the TFS work item tracking system? TFS is very flexible when it comes to adding fields, rules and state transitions. But when we need more specialized behavior there is usually only one solution – to implement custom work item controls. It’s pretty straight-forward to implement a work item control (http://witcustomcontrols.codeplex.com/ has some good examples), but we need to implement the control for each client we want to use it (Visual Studio, Web access) and also the control must be deployed to each machine where the client is run.

A much simpler approach can be to implement the extension as a web page and host the web page in the work item form. This solution works with any client (since it’s just a web page) so you won’t have to have one implement for each client type. In TFS 2010 the WebpageControl was introduced, which can be used to host a custom web page inside a work item form. We can configure the control to pass data from the work item to the web page when the control is displayed. So with the WebpageControl we can use the TFS API to write a web page that can surface more or less any data in the work item UI.

In this example I will extend the Test Case work item type with a tab that shows the test suites where the test case is used together with the status of the latest test run in each of the suites.

Note: it’s recommended to work with TFS customization in a sandbox environment so you don’t disturb production use of your TFS. A very easy way to get a development environment for TFS is to use Brian Keller’s Visual Studio / TFS 2012 virtual machine.

The WebpageControl isn’t that much documented on MSDN so I’m going take you through the steps of extending a work item type with the control and linking it to a custom web page.

  1. Implement the web page for the extension you want. Since this is just a web application it’s simple to develop, debug and test the extension. Design the page so data can be passed from the work item to the page using URL parameters.

    image
  2. Add a WebpageControl to the work item type. The easiest way to add a control is to use the Process Template Editor (part of the TFS Power Tools):

    image

    Make sure to set the Dock property to Fill if you want the control to use the whole tab space.
  3. Configure the WebpageControl using the Control Settings:

    image

    Set the URL to display and other properties as appropriate:

    image

    Note the use of field names. You can reference any field with it’s unique reference id, for instance the Team Project name would be $(System.TeamProject).
  4. Save and update the work item type definition. Refresh the client you are using to make sure the test case type definition has been updated.
  5. Open a test case and see the new control with the custom web page content appear under the Test Suites tab.

    image

Simple, wasn’t it? Feel free to leave comments on what you think of this approach.

Microsoft Sommarkollo 2013 (swe)

För elfte gången håller Microsoft sommarkollo, i år i Göteborg, Stockholm och Malmö. Det är kostnadsfritt så passa på att unna dig några sessioner om de senaste trenderna och produkterna från Microsoft!

image

Jag är glad att få vara med på evenemanget och kommer presentera dessa två sessioner:

Båda går först i Göteborg den 26 juni och sedan 15 augusti i Stockholm (där min kollega Magnus Timner kommer vara med).

Passa på att boka en plats nu på en gång!

Book project #2 – Pro Team Foundation Service, done!

I’m happy to share the release of the second book I’ve been involved in. This time the subject is the Team Foundation Service and how it can be used to setup a complete development infrastructure in just a couple of minutes. Oh, well, at least that’s what it takes to create an account… To fully take advantage of all its capabilities obviously will take much longer but hopefully the practices and experience we share in this book will help you get going quickly.

I’ve had the opportunity to work with a great team to author the book, with co-authors Jakob Ehn, Mattias Sköld and Joachim Rossberg. We’ve got great input and feedback from people in the product group, thanks Jamie, Will, Ravi, Anu, Vijay and Ed! And not to mention our most thorough reviewer Terje Sandstrøm. And thanks to Brian Harry for writing the foreword!

image

You can read more about the book at Amazon: http://www.amazon.com/Team-Foundation-Service-Mathias-Olausson/dp/1430259957.

Hope you find the book useful, I definitely learnt a lot from writing it!

Community TFS Build Extensions – January 2013 Release is out

As planned Mike Fourie published the January 2013 release of the Community TFS Build Extensions. This must-have pack of TFS build extensions has now gotten another set of new features added as well as issues fixed.

Release notes

The January 2013 release contains

  • VS2010 Activities(target .NET 4.0)
  • VS2012 Activities (target .NET 4.5)
  • Community TFS Build Manager VS2012

The Community TFS Build Manager can also be found in the Visual Studio Gallery here where updates will first become available. A version supporting VS2010 is also available in the Gallery. Please note that we only intend to fix major bugs in the 2010 version and will concentrate our efforts on the 2012 version of the TFS Build Manager.

At a high level, the following Issues and Features have been addressed

Activities
11237 Add support for /project switch on VsDevEnv activity Feature
11256 VsDenEnv : error if no DropLocation is specified Issue
11136 NUnit Result Publishing Issue
11423 NAnt activities Task
11250 The CodeMetrics activity throws an exception if DropLocation isn’t set Issue
11307 vb6 project compilation – add time out Feature
11360 Statlight publish to TFS Issue
10635 Allow additional parameters for StatLight activity Issue
11212 StyleCop build activity doesn’t write true to Succeeded on success Issue
11373 Issue with the TransformConfig-Activity Issue
11544 Statlight does not work with VS2012 Issue


TFS Build Manager
11515 TFSBM – Don’t show deleted branches for Cloning Issue
11113 Exception if no projects in collection Issue
11226 Clone to branch with spaces in name throws BuildServerException Issue
11309 TFSBM — Retain All Builds Feature
11407 TFSBM – update icons and add to Team Explorer Feature
11495 TFSBM – TE Navigation Link opens TFSBM in wrong VS instance Issue
11114 Manage Build Resources Context Menu uses wrong icons Issue
11241 No vertical scrollbar Issue


Note: If you are using the Azure Activities in VS2010 you should continue to use the April release. We will release a new build of this activity once we resolve the current VS2012 dependency which has been introduced.

WIT Custom Controls for TFS v1.1.1.0 Released

I just pushed an update to the Custom Controls for TFS (WITCustomControls) project today. The project has been idle for a while but I decided to do a some work to enable the controls to work with TFS 2012. Soon after that pseranne contributed with a TFS 2012 Web control for the MultiSelectList control, which is the reason for the latest release.

These are the two recent changes:

1.1.0.0 release added support for TFS 2012 Windows Controls.

1.1.1.0 release added the MultiSelectList as a Web Control for TFS 2012 making the control available seamlessly in all TFS clients:

Web

image

Visual Studio

image

Microsoft Test Manager

image

Read more and download the controls from http://witcustomcontrols.codeplex.com/

Testing for Continuous Delivery with Visual Studio 2012

Microsoft Patterns and Practices just release a new "blue book”, this time covering many testing practices using Visual Studio ALM 2012 as the foundation. The book has a nice scenario-oriented approach with good practical examples to get you started.

image

The book is available for free and can be downloaded here: http://www.microsoft.com/en-us/download/details.aspx?id=35380

TechDays 2012 Sweden – Come see Visual Studio ALM 11 and TFS 11 in action!

Today is the start of Microsoft TechDays 2012 in Sweden. TechDays is probably the largest IT conference in Sweden this year, three days filled with great content covering everything from IT operation to cloud-based development.

image

I’m proud to get a chance to talk at the conference again and this time on the following topics (yes, Visual Studio 11 ALM as expected):

  • Build Lab in the Sky
  • Continuous Feedback

And as if this is not enough, Brian Keller from Microsoft DPE will give the big picture presentation on ALM:

  • What’s new in Visual Studio 11 for Application Lifecycle Management
  • Software Testing with Microsoft Test Manager 11 and Lab Management 11

 

 

 

Another great thing about TechDays is that you get a chance to connect to the smart people in MEET (Microsoft Extended Experts Team), a group of technology experts, MVPs and MCTs I happen to be a part of. Here are some of the MEET members blogs if you want to learn more about the MEET members:

  • Andreas Stenhall
  • Alan Smith (Azure)
  • Björn Axell (System Center)
  • Cecilia Wiren (.NET)
  • Chris Klug (.NET)
  • Daniel Bugday (Sharepoint)
  • Hasain Alshakarti (Security)
  • Henrik Nilsson (FIM, ADFS, Security)
  • Johan Arwidmark (System Center)
  • Johan Åhlén (SQL Server)
  • Magnus Björk (Exchange)
  • Magnus Mårtensson (Azure)
  • Patrik Löwendahl (.NET)
  • Mathias Olausson (ALM)
  • Jörgen Nilsson (System Center)
  • Ola Skoog (IT Pro Evanglist)
  • Anders Olsson (Security)
  • Joakim Nässlander (Windows Server, Cluster)
  • Martin Lidholm (Unified Communication, Lync)
  • See you at TechDays 2012 I hope!

    More about the Community Build Manager

    In a previous post on the TFS Build Extensions I mentioned the new Community Build Manager and that I will write a post and explain more what it does. But who can do it better than one of it’s author’s Jakob Ehn so take a look at his fine post on the subject:

    http://geekswithblogs.net/jakob/archive/2011/12/30/introducing-community-tfs-build-manager.aspx

    Download and try it out, I really like this nice Visual Studio/TFS add-on!