Skip to content
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

[Test API] not able to disable individual test run/debug with RunProfile #129450

Closed
connectdotz opened this issue Jul 26, 2021 · 3 comments
Closed
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s)

Comments

@connectdotz
Copy link

connectdotz commented Jul 26, 2021

Issue Type: Bug

In our extension (vscode-jest), we used the external jest watcher to auto-run tests when the tests or related source files change. In such use case, we used to disable manual test run for the individual test items (TestItem.runnable = false), while still supporting "restarting" the jest watch run for the workspace item. However, after switching to the new RunProfile, we lost the ability to disable the test run on the TestItem level and it would not make sense to fall back to "restart" jest run for the whole workspace...

Similar issue for debugging: we used to only support debugging on the file and individual test level, how to achieve this with the RunProfile?

We end up throwing errors in runTest to prevent the unsupported run/debug, which of course is not ideal. I know this issue has been raised in other discussions, this is now impacting our implementation, hopefully, it will get more urgent priority before release.

VS Code version: Code - Insiders 1.59.0-insider (Universal) (955a1ac, 2021-07-26T05:12:43.446Z)
OS version: Darwin x64 20.6.0
Restricted Mode: No

System Info
Item Value
CPUs Intel(R) Core(TM) i7-8700B CPU @ 3.20GHz (12 x 3200)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: enabled
opengl: enabled_on
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 3, 4, 3
Memory (System) 32.00GB (2.79GB free)
Process Argv --enable-proposed-api Orta.vscode-jest --crash-reporter-id bb07f68d-9e6c-4982-a12f-528f81d06cb6
Screen Reader no
VM 0%
@connectdotz connectdotz changed the title [Test API] not able to disable individual test run with RunProfile [Test API] not able to disable individual test run/debug with RunProfile Jul 26, 2021
@weinand weinand assigned connor4312 and unassigned weinand Jul 26, 2021
@connor4312
Copy link
Member

connor4312 commented Jul 26, 2021

The plan for this is to introduce test tags: #122208 (comment) (edit: dedicated issue for it #129456 )

Let me know if you see any problems with that for your scenario.

@connectdotz
Copy link
Author

thanks, @connor4312 As long as we can enable/disable the runProfiles at the TestItem level and update the UI (run/debug buttons) accordingly, it should work. But maybe we can get away with yet another identifier like tags? Anyway, I left the comment in #129456 for further discussion

@connor4312
Copy link
Member

Ok, cool. Let's merge this into that one then

@connor4312 connor4312 added the *duplicate Issue identified as a duplicate of another issue(s) label Jul 26, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests

3 participants