a·gen·tic a·gil·i·ty

Fail a build if tests fail

Explains how to configure TFS 2008 builds to automatically fail if any tests fail by setting TreatTestFailureAsBuildFailure to true in the build project file.

Published on
1 minute read
Image
https://nkdagility.com/resources/VuY5udPg1uD
Subscribe

It took me longer than I thought it would to find this, but is you are using TFS2008 and you want builds to fail if any of the tests fail then you can add the following to the tests properties group in your build project (TFSBuild.prof)

 1<PropertyGroup>
 2  <!-- TEST ARGUMENTS
 3   If the RunTest property is set to true, then particular tests within a
 4   metadata file or test container may be specified here.  This is
 5   equivalent to the /test switch on mstest.exe.
 6
 7   <TestNames>BVT;HighPriority</TestNames>
 8  -->
 9  <TreatTestFailureAsBuildFailure>true</TreatTestFailureAsBuildFailure>
10</PropertyGroup>

Very handy…

Technorati Tags: TFBS   ALM   TFS 2008

Software Development
Subscribe

Related Blog

No related videos found.

Connect with Martin Hinshelwood

If you've made it this far, it's worth connecting with our principal consultant and coach, Martin Hinshelwood, for a 30-minute 'ask me anything' call.

Our Happy Clients​

We partner with businesses across diverse industries, including finance, insurance, healthcare, pharmaceuticals, technology, engineering, transportation, hospitality, entertainment, legal, government, and military sectors.​

Graham & Brown Logo

Graham & Brown

Epic Games Logo

Epic Games

Kongsberg Maritime Logo

Kongsberg Maritime

ProgramUtvikling Logo

ProgramUtvikling

NIT A/S

Capita Secure Information Solutions Ltd Logo

Capita Secure Information Solutions Ltd

Big Data for Humans Logo

Big Data for Humans

Boeing Logo

Boeing

Akaditi Logo

Akaditi

DFDS Logo

DFDS

Ericson Logo

Ericson

Trayport Logo

Trayport

Illumina Logo

Illumina

Philips Logo

Philips

Alignment Healthcare Logo

Alignment Healthcare

SuperControl Logo

SuperControl

Microsoft Logo

Microsoft

MacDonald Humfrey (Automation) Ltd. Logo

MacDonald Humfrey (Automation) Ltd.

Department of Work and Pensions (UK) Logo

Department of Work and Pensions (UK)

Nottingham County Council Logo

Nottingham County Council

Washington Department of Enterprise Services Logo

Washington Department of Enterprise Services

New Hampshire Supreme Court Logo

New Hampshire Supreme Court

Washington Department of Transport Logo

Washington Department of Transport

Royal Air Force Logo

Royal Air Force

Capita Secure Information Solutions Ltd Logo

Capita Secure Information Solutions Ltd

Flowmaster (a Mentor Graphics Company) Logo

Flowmaster (a Mentor Graphics Company)

Ericson Logo

Ericson

Lockheed Martin Logo

Lockheed Martin

Freadom Logo

Freadom

Brandes Investment Partners L.P. Logo

Brandes Investment Partners L.P.