Scenario
- Visual Studio Online build definition.
- Using a Visual Studio Test - Test Assemblies step to run tests in a specific dll.
- The tests in this dll are more like build steps (highly customized builders), than tests.
- The test step has "Continue on error" set to false as I need it to fail when one of the builders fails. And this is working as expected. When a test step fails, the build fails.
Due to changes in test runners, currently no tests are discovered because of a mismatch between the test framework in the dll and the test run adapter used in the build. (I know how to fix this, that isn't the problem.)
The problem is that this only produces an information message in the logs about no tests having been discovered and a warning that there were no testresults to publish, making the build present (on the surface) as successful. A false-positive that I'd like to get rid off.
What do I need to do to make "no tests discovered" fail the build?
I have looked into vsts testrunner configuration with a .runsettings
file (https://msdn.microsoft.com/en-us/library/jj635153.aspx), but don't see any options to get this behavior?