Using Team Foundation Build, I'm invoking the xunit.net xunit task, which is /platform:AnyCpu
, but my TeamBuild invocation of the TFSBuild.proj is vanilla.
I have a number of tests that are x64 specific (`/platform:x64'), which choke with an ImageFormatException. I have also a test asembly that's marked x86 so it can't be all or nothing.
NUnit has a platform switch on the MSBuild task, xunit doesnt.
I can think of the following approaches:
- invoke a 64 bit msbuild child task to invoke the xunit task - there isnt a ToolPath param, so if that's a good idea, what's the cleanest Exec task syntax to do that, passing in the child environment?
- special case the invocation of the 64 bit with xunit.console.x64
- switch the entire TeamBuild over to x64 and special case the x86 (but that just lands me in the inverse situation of needinn to special case the x86). (I also assume that other than having to make sure custom tasks are in the right PROGRA~...\MsBuild dir, there's probably going to be more hassle)
What have others had success with in handling issues like this?