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

Dynamically defined tests (using ScalaTest) hang when ran from the IDE #6815

Open
adamw opened this issue Sep 30, 2024 · 2 comments
Open

Dynamically defined tests (using ScalaTest) hang when ran from the IDE #6815

adamw opened this issue Sep 30, 2024 · 2 comments
Labels
bug Something that is making a piece of functionality unusable debug DAP debug related tickets investigation needed test-explorer

Comments

@adamw
Copy link

adamw commented Sep 30, 2024

Describe the bug

Running the SourceOpsMapParTest tests from Ox never finishes. There's an endlessly spinning wheel:

image

In the debug console, I can see that the tests have finished:

===============================================
Total duration: 9.63s
All 1 test suites passed.
===============================================

Stopping the tests does nothing (using the square button on the right in the "test results" window). Sometimes this happens on the first test run, sometimes the first completes successfully, and only the second fails.

Moreover, quitting VS Code (which I'm using as the metals host) doesn't kill the Metals-started bloop.Server process. I have to manually kill it after I exit VS Code (which shuts down cleanly)

Expected behavior

  1. the tests are nicely reported in the "test results" window, or at least - not hang.
  2. existing VS Code cleans up any processes that have been started

Operating system

macOS

Editor/Extension

VS Code

Version of Metals

1.3.5

Extra context or search terms

No response

@tgodzik tgodzik added bug Something that is making a piece of functionality unusable debug DAP debug related tickets test-explorer labels Oct 7, 2024
@adamw
Copy link
Author

adamw commented Oct 8, 2024

In fact this happens from time to time on "normal" tests as well (using ScalaTest), although the class above is the best way to reproduce the problem

@adamw
Copy link
Author

adamw commented Oct 17, 2024

As a work-around, I found that while the "cancel test run" that appears in the bottom-right corner is basically a no-op, a bar (also used for debugging) at the top appears, with a red "stop", which does work.

Still, occasionally the tests hang, and when closing metals the bloop process remains, meaning that I have to periodically do a killall -9 java ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something that is making a piece of functionality unusable debug DAP debug related tickets investigation needed test-explorer
Projects
Status: Triage
Development

No branches or pull requests

2 participants