4

I have team build running on a TFS 2008 server. I want it to run my xUnit.net tests there and show the result in the Build details.

I know I have to do a lot of configuration in the TFSBuild.proj script file. I already managed to make the tests run, but the result does not appear in the build. I followed the instructions from mehfuz's blog.

Looking at other similar question, I got to Jonne Kats' post. Unfortunately, it's kind of obsolete. There's a lot a workaround included to overcome the lack of an ExitCode in the xunit task. With xunit 1.7, this is not required anymore.

I'm having a hard time trying to set this up. Can someone show me a way to publish the test results into the team build?


Update: I see that my question actually consists of a lot of small questions. Let me make it more direct.

I'm running an Xunit.Runner.MSBuild.xunit task successfully. It is set to generate a XML file with a test report. In order to show this report in the TFS Build Details, I need to import it using MSTest.exe. However, I must first convert it to a format that MSTest will understand.

Does anyone has a XSLT file that I could use for transforming the xUnit XML report into a MSTest TRX file?

Community
  • 1
  • 1
jpbochi
  • 4,366
  • 3
  • 34
  • 43
  • possible duplicate of [NUnit: XSLT to transform NUnit output to MSBuild errors and warnings format](http://stackoverflow.com/questions/2721254/nunit-xslt-to-transform-nunit-output-to-msbuild-errors-and-warnings-format) –  Mar 17 '11 at 20:01
  • user357812: It's related, but not a duplicate: this question is about XUnit, not NUnit. – Ronald Zarīts Aug 26 '11 at 16:13
  • jpbochi: have you found a solution? – Ronald Zarīts Aug 26 '11 at 16:16
  • @ghostskunks: If I remember correctly, I built my own TFS task to solve the problem. Unfortunately, I'm working on a different place now and I don't have access to the code anymore. PS.: Sorry for the extremely late response, I don't think I received any alerts for it. – jpbochi Jan 27 '12 at 03:08

1 Answers1

0

A very promising article is posted here: http://salvoz.com/blog/2010/02/22/transform-xunit-to-mstest/

Unfortunately, the XSLT has been mangled a bit by the blog engine, and I haven't put in the effort to get it working yet.

Ronald Zarīts
  • 11,819
  • 8
  • 39
  • 42