-
-
Notifications
You must be signed in to change notification settings - Fork 96
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
Can Test Explorer match the Expecto folder hierarchy? #431
Comments
@baronfel I'm taking up your suggestion to try Expecto (via https://github.com/YoloDev/YoloDev.Expecto.TestSdk) and it's good so far but I'm stuck at this point. |
Even "Rectangular hierarchy", in which folders of degree 0 contain only tests, and folders of degree n contain folders of degree n-1, and the main degree is 3, doesn't work: There seems to be a big problem connecting Expecto to Test Explorer. Test Explorer may be hacked together with strings but it definitely allows for deeper hierarchies than this. Am I right in posting here rather than in https://github.com/YoloDev/YoloDev.Expecto.TestSdk ? |
Hi. I don't use Visual Studio very much anymore, but back in the day I used to use adamchester/expecto-adapter. It looks like it's been archived since then (I guess people use YoloDev.Expecto.TestSdk for that now), but I remember getting the nesting in the VS Test Explorer to work fine. See screenshot in adamchester/expecto-adapter#47. You could try seeing if it still works but it might need an older version of VS. Usually I just use the terminal for running tests now ( The nesting works fine for what you had in your "Rectangular hierarchy". "Some other test" doesn't even show up in the right place though, it should be nested under "List". There seems to be an issue with it Ionide or VSCode though. When I try to run tests from the test explorer it just hangs indefinitely showing the spinner. Nothing shows up in any of the VSCode output logs. The output of
|
Note that the VSCode feature is in its infancy, so I'd err on the side of a bug in our test discovery and execution. This issue should focus purely on the discovery and execution of expecto tests via the Yolodev adapter, which provides the bridge to the 'dotnet test' world that powers the CLI and VS experiences. |
How does the VSCode feature discover and execute tests then (and where is it implemented?) if it's not with the yolodev adapter? I thought it runs something like But agreed, this issue should focus on the Yolodev adapter with VS |
The discovery happens via syntax analysis, which is way faster but not as accurate. The execution should happen via dotnet test, however. Can you raise an issue about any test execution issues on the Ionide VSCode repo? |
Given tests in a folder structure:
Is there a way to have Test Explorer match this?
Project, Namespace, Class isn't right
Project, Class isn't right either
@cmeeren in #364 was getting some correspondence, but the samples there are very constrained - every test is exactly 2 levels deep in the hierarchy.
Is there a spec for the Test Explorer behaviour, or should I figure out by trial and error what Expecto structures result in what outputs and then try to make a set of consrained types (FolderLevel1, FolderLevel2) and then try to generate an altered Expecto folder structure to get the desired Text Explorer behaviour?
The text was updated successfully, but these errors were encountered: