Replies: 1 comment 1 reply
-
I think this ties in with scalacenter/bloop#996 I think Bloop and SBT deliberately exclude non-public classes from test discovery. I understood at the time this was for performance reasons. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there :)
I'm currently evaluating VSCode with Metals as an alternative to Idea and I've just found an interesting difference in test discovery:
We are using ScalaTest and to keep the classes clean and separate, we are declaring all test suites/classes as
private final
by default. In Idea and maven, those tests are discovered and run without any issues. In VSCode with Metals however, the private test suites don't show up at all.Now I'm not sure if that is a bug or somehow intended behavior. That's why I'm starting a discussion rather than opening an issue ;)
Any insight would be appreciated!
Here are two simple examples:
This one is discovered by Maven, Idea and Metals:
This one is only being discovered by Idea and Maven:
As soon as I change the visibility modifier of
PrivateTest
, it shows up in the TestExplorer.Beta Was this translation helpful? Give feedback.
All reactions