The JustMock Code Activity Workflow for Team Foundation Server 2012 is designed to deploy your JustMock test
projects to TFS 2012 with zero manual configurations for setting up your build environment.
It breaks you free from tedious configuration of environment variables and provides you simple options
that can get you on the move in no time. In this topic we will focus on what are the required configuration
steps when working with JustMock Code Activity Workflow for TFS 2012.
First, you need to point the custom assemblies folder that contains the Telerik.JustMock.Build.Workflow.VS2012.dll
to your build controller.
The DLL is included in the JustMock installation directory under the
Do this by editing your build controller properties. Go to Team Explorer, then
Builds and from the Actions menu select
Manage Build Controllers. You will be prompted with a dialog similar to the one below:
Then you have to set the
"Version control path to custom assemblies"
property to the location of the folder containing the Telerik.JustMock.Build.Workflow.VS2012.dll.
Continue by customizing the DefaultTemplate.11.1.xaml you wish to update. Follow the next steps:
Start by adding the the build precess template under Source Control in your project.
Then, open the Build Definition and in the Process tab >
Build process template field, click New...
Browse the above build process template and select it as default to the project.
To edit the template, first check it out from Source Control.
Then, create new class library project (This will be a dummy project. Its only purpose is for editing the template.
You don't need to add it to your solution or project collection) and refer the
Include the downloaded build process template in the class library project, using the
Add as Link option.
Set its Build Action to None.
For the changes to take effect, later on you will need to save the "dummy" project and
check-in the build process template.
Below is a screenshot of a section from the Default Template (DefaultTemplate.11.1.xaml):
You need to wrap the Run Tests activity with the custom JustMockStart/JustMockStop
activities from the Telerik.JustMock.Build.Workflow.VS2012.dll.
In order to drag/drop the JustMock activities to your build template, you have to add the
assembly into your Toolbox pane. Do this by opening Tools >
Choose Toolbox Items. Then, select Browse and point to the
Telerik.JustMock.Build.Workflow.VS2012.dll in your custom assemblies folder
(in this example: $/JustMockActivityWorkflowProject/Addons).
After placing the JustMock activities, your template must look like this:
Optionally, set the LinkProfilers parameter on JustMockStart to link 3rd party profilers, for example "Visual Studio 2012 Code Coverage/IntelliTrace".
Multiple profilers can be specified by separating them with a semicolon. The names of the profilers must be specified
exactly as they appear in the UI of the JustMock configuration tool. The files Telerik.JustMock.Configuration.exe
and Telerik.JustMock.Configuration.exe.config must be present in the same folder as Telerik.JustMock.Build.Workflow.VS2012.dll.
To unlink profilers, set the UnlinkProfilers parameter on JustMockStop.
Finally, save the "dummy" project and check-in the process template!
Once all is set, your JustMock tests that require profiler will work as expected.