Skip to content

[JUnit Platform] Support discovery selectors with FilePosition #2121

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

Merged
merged 1 commit into from
Sep 14, 2020

Conversation

mpkorstanje
Copy link
Contributor

@mpkorstanje mpkorstanje commented Sep 13, 2020

There was no good way to discover and execute a single test when using a file
based test system like Cucumber. Recently JUnit added support for file position
in the FileSelector and ClasspathResourceSelector.

See: junit-team/junit5#2146

This implements a filter that prunes all scenarios that do not match the
FilePosition from the discovery selector. This feature itself is not new. It
was already implemented for the UriSelector.

This feature will benefit the implementation of IDEA-227508. If you would like to use this feature in the future please up up-vote it.

TODO:

  • Create demo project for the benefit of the IDEA/Eclipse people.
  • Create issue to track feature request with IDEA/Eclipse/VsCode/Gradle/Maven ect

@mpkorstanje mpkorstanje force-pushed the junit-platform-select-lines branch from 43facec to f800c60 Compare September 13, 2020 19:54
@coveralls
Copy link

coveralls commented Sep 13, 2020

Coverage Status

Coverage increased (+0.02%) to 86.499% when pulling 00dbbd4 on junit-platform-select-lines into c03e1d4 on main.

@aslakhellesoy
Copy link
Contributor

Wow amazing!

@mpkorstanje mpkorstanje force-pushed the junit-platform-select-lines branch 6 times, most recently from 560676b to b3e18b5 Compare September 14, 2020 16:32
There was no good way to discover and execute a single test when using a file
based test system like Cucumber. Recently JUnit added support for file position
in the `FileSelector` and `ClasspathResourceSelector`.

See: junit-team/junit5#2146

This implements a filter that prunes all scenarios that do not match the
`FilePosition` from the discovery selector. This feature itself is not new. It
was already implemented for the `UriSelector`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants