Richard Hundhausen pointed out this blog post recently, and I thought I’d mention it here.  Rob Maher walks through the process of setting up a build definition to run only the tests that involve the code that was changed.

TFS 2010 Build - Only run impacted tests

If your tests take a long time to run, you may wish to only run the tests that have been impacted by code changes checked in with the build (and of course run a full nightly build that executes all tests :) Unfortunately there is no out of the box feature to do this, so we need to edit our build xaml to do it.

more…