At my current project we use Team Foundation Server together with the possibility to have a daily build through MSBuild. Over the weekend, the build failed. Because our ‘build master’ called in sick this morning, I took it upon me to fix the build. But compiling the sources was no problem, because that finished without any errors. And there were no failing (unit)tests. Even better: there were no tests which had run at all! There were ‘no test results to display’. The only thing I found in the build log (which is pretty big in a 70+ project solution!) that could indicate a problem was a warning from MSBuild:
MSBUILD : warning : Specified cast is not valid
And, just below that line, the following one:
The previous error was converted to a warning because the task was called with ContinueOnError=true.
After some searching and trying, I found out TFS / MSBuild doesn’t like it when your vsmdi file contains a list or sublist that doesn’t contain any tests to run. Somehow this feels like a bug, because parsing the testlist fails when it has no members. List != null && List.Count > 0 anyone?