Accessing ReturnCode from NUnitTeamCity task
The ReturnCode property of the NUnitTeamCity task seems like an obvious candidate for something that should be accessible when the task exits. However, if I define a task like this:
<NUnitTeamCity
Assemblies="@(TestAssemblies)"
NUnitVersion="NUnit-2.5.4"
>
<Output TaskParameter="ReturnCode" ItemName="NUnitExitCodes"/>
</NUnitTeamCity>
I receive the following message:
error MSB4065: The "ReturnCode" parameter is not marked for output by the "NUnitTeamCity" task.
I think this should be a simple matter of adding an attribute - is this something you could fix in the next release?
Please sign in to leave a comment.
I've added an issue into issue tracker at http://youtrack.jetbrains.net/issue/TW-12754, please vote for it.
Note, I've added a question for you there.
Hi Eugene, thanks for looking at this. I've commented on the issue in the tracking system, but I'm copying some of the reply here to see if anyone has another suggestion to achieve what I want.
The scenario I am thinking of is where I want to run tests from multiple assemblies by using MSBuild batching, and I want to:
At the moment this is not easy with the NUnitTeamCity task. Is there another way to achieve this with the current tools?
You may switch to using TeamCity NUnit launcher.
Please have a look at http://confluence.jetbrains.net/display/TCD5/TeamCity+NUnit+Test+Launcher for more details.