Dictating parallelism via extension #3476
Replies: 2 comments 3 replies
-
That's a good question, and the short answer is "No, not an But... we do have support for controlling the See For the sake of clarity, it is actually not possible for an However, I have also wanted support for this. For example, when a Spring integration test uses If we were to introduce such a feature, we'd need a way to register "something" (I'm not calling it an extension because I don't think it can be an @marcphilipp, thoughts? |
Beta Was this translation helpful? Give feedback.
-
This feature request sounds quite similar to #2677, except the linked issue would apply not just to test classes but individual tests, too. It would simplify JUnit Pioneer's resources injection extension a fair bit, which uses Java locks to force tests that use the same resource to run sequentially. |
Beta Was this translation helpful? Give feedback.
-
Is it possible for a custom JUnit 5 extension to disable parallelism for the classes that it applies to?
For Android development, UI tests claim the full attention of the device, so it's impossible to run multiple of these tests in parallel (this is also enforced by Espresso, the underlying test library used for Android). Of course, I could tell users to use
ExecutionMode.SAME_THREAD
for any test class that uses my custom extension for UI tests with JUnit 5, but it would be nice if this could be dictated by the extension itself.Thoughts? Thanks!♥️
Beta Was this translation helpful? Give feedback.
All reactions