Closed hoetz closed 5 years ago
Ok, adding "Fact" here is a first step and on my local dev version the tests already show up. dotnet test starts but it's waiting for the debugger to attach but it never does 🤔
The "Debug Test" code lens issues a custom notification that invokes this function:
So it's basically just a question of making that function support xunit.
Also, the debugger starts paused for some complicated reason that I forget. So you may just need to press play...it would be nice if that were not necessary, obviously.
Indeed, pressing "play" worked :) The pull request I submitted provides support for Fact / Theory tests and is certified "works on my machine"
For future reference, this is how omnisharp implements test detection https://github.com/OmniSharp/omnisharp-roslyn/tree/6836fadb9c35a88d4695276d14302336a460b841/src/OmniSharp.DotNetTest/TestFrameworks
The problem with that approach is you have to parse and typecheck the code, and typechecking takes time, especially in F#. Code lenses need to be computed fast, so we have to figure out how to find the test methods by just parsing the code.
What would it take to get xunit tests decorated with [Fact] et al. to work with the debug test command?