-
Notifications
You must be signed in to change notification settings - Fork 30.2k
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
XUnit v3 packages cause VSCode 'codelens' debugging to become unavailable (tests are otherwise discovered okay in the sidebar) #237197
Comments
This would indicate that the debug extension is not associating a location (file or range) with the tests. Just doing a quick search on their extension it seems like other users might have this problem too, e.g. microsoft/vscode-dotnettools#1704 |
This issue is caused by an extension, please file it with the repository (or contact) the extension has linked in its overview in VS Code or the marketplace for VS Code. See also our issue reporting guidelines. If you don't know which extension is causing the problem, you can run Happy Coding! |
I disagree with the analysis that "we're not providing source information", because something is allowing a user to navigate from the test window to source code correctly (and that something is the source & line number metadata that is claimed isn't present). The below video was captured using Recording.2025-01-06.105057.mp4Can you please explain to me why navigation from the test tree into the source code works, but the icons don't, in a way that is our fault? |
@connor4312 can you reopen please and review @bradwilson 's information? Thanks. |
You case looks different from the reporter's. The reporter said that navigation stops working and the "run" buttons disappear, which is behavior consistent with a missing test location (their 3rd screenshot). In your case it seems like navigation works and the run buttons do appear correctly -- I don't see any issues with your recording. |
Sorry, I may have simultaneously fixed the issue and misunderstood how it surfaced. 😬 😂 |
All good, let me know if you run into anything else that might be vscode side :) |
Already opened as a bug on xunit but they think this is a VSCode issue: xunit/visualstudio.xunit#433.
Reproduction at: https://github.com/kieranbenton/MyFirstUnitTests ready to go.
Steps to Reproduce:
(NOTE: These are from scratch, but you can use the reproduction above to skip to the end).
Follow the https://xunit.net/docs/getting-started/v2/netcore/cmdline tutorial
Confirm that the minimal fact created as part of that is discoverable in the VSCode 'Testing' panel AND that the code lens actions are available for it
Nothing particularly smoking-gun esque in logs that I can find:
The text was updated successfully, but these errors were encountered: