-
Notifications
You must be signed in to change notification settings - Fork 588
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MSTest: add Tests parameter to specify list of tests #1615
MSTest: add Tests parameter to specify list of tests #1615
Conversation
Sorry for the delay. The change looks good, thanks! Can we migrate the MSTest module to FAKE 5 as suggested in https://fake.build/contributing.html. Let me know if you need help. |
no problem. gimme couple of days |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I can merge and release this once the build is green. Let me know if there are further bootstrapping problems.
build.fsx
Outdated
@@ -34,6 +34,7 @@ open Fake.DotNet.Cli | |||
open Fake.Testing.Common | |||
open Fake.DotNet.Testing.MSpec | |||
open Fake.DotNet.Testing.XUnit2 | |||
open Fake.DotNet.Testing.MSTest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have a small bootstrapping problem with this ;). I think we can remove those lines for now.
src/app/FakeLib/FakeLib.fsproj
Outdated
@@ -306,6 +306,9 @@ | |||
<Compile Include="UnitTest\MSTest.fs" /> | |||
<Compile Include="UnitTest\ProcessTestRunner.fs" /> | |||
<Compile Include="UnitTest\VSTest.fs" /> | |||
<Compile Include="..\Fake.DotNet.Testing.MSTest\MSTest.fs"> | |||
<Link>Fake.DotNet.Testing.MSTest/MSTest.fs</Link> | |||
</Compile> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we move that up to the other "Modules"? This prevents accidental usage of "old" members (and makes the IDE help you)
OK Travis is still failing:
I think we need to disable the tests on mono. |
let mstestexe =
if Environment.isWindows then "mstest.exe"
else failwith "MSTest is only supported on Windows platform"
|
absolutely :)
Personally I'm ok with everything that works ... (Don't know MSpec good enough tbh.) |
Hey! Thanks for fixing this, really looking forward to testing it (pun intended -_-')! I noted when creating the mstest argument string manually that it is fairly simple to reach the maximum allowed length of windows command line, somewhere around 8000 characters. Our tests can have names closer to 200 chars long. :< Does FAKE handle this, or is it something that should be included here? |
@walliski How could FAKE handle this? To be honest I'm not even sure what would happen if you reach the limit. Maybe windows will strip the commandline or will yield an error? |
FAKE could either warn/throw error about it, or then split the execution into multiple parts with a set of tests in each. Alternatively I've understood, though not tested, that you should be able to split the command into multiple lines and this might mitigate the problem. Although this seems to be a bit of a fuzzy area of Windows. Windows throws an error and wont run the command. |
Hello, please review this PR.
This is a fix for #1601 (MSTest /test support).
Sample usage: