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

Fix NoClassDefFoundError with JUnit 5.9 #137

Merged
merged 5 commits into from
Dec 26, 2022
Merged

Conversation

jenschude
Copy link
Contributor

@jenschude jenschude commented Dec 16, 2022

Signed-off-by: Jens Schulze [email protected]

Overview

With version 5.9 of Junit Jupiter engine the ExecutableInvoker class became an interface.

Also the ConfigurationParameters got a new method keySet with 5.9.

It should be noted that the API annotations by JUnit are not correct. The keySet method is annotated as available since 1.9 but has been introduced with 5.9 too.

This change means that the minimum version for the dataprovider will be 5.9.0 for junit jupiter engine and parameters

Fixes #136


I hereby agree to the terms of the JUnit dataprovider Contributor License Agreement.


Definition of Done

  • There are no TODOs left in the code
  • Method preconditions are checked and documented in the method's Javadoc
  • Change is covered by automated tests (unit and/or integration tests)
  • Build has passed

@coveralls
Copy link

coveralls commented Dec 16, 2022

Coverage Status

Coverage decreased (-0.2%) to 92.468% when pulling d81e91e on jenschude:fix-junit-5_9 into 632b72c on TNG:main.

@jenschude
Copy link
Contributor Author

I changed the code from using the InterceptingExecutableInvoker to the DefaultExecutableInvoker as the last one is using the ExecutableInvoker interface.

As already stated in the issue comment. It may be worth to investigate using the Invoker from the context object. I tried it, but seems that the context registry is not correctly filled necessary extensions so some tests failed.

@aaschmid
Copy link
Member

Thanks for the PR @jenschude. I will try to have a deeper look at this weekend...

Signed-off-by: Jens Schulze <[email protected]>
@aaschmid aaschmid merged commit 4ace908 into TNG:main Dec 26, 2022
@aaschmid aaschmid added this to the v2.9 milestone Dec 26, 2022
@aaschmid
Copy link
Member

Thanks @jenschude, fixed with v2.10 which should appear shortly on Maven Central.

@jenschude jenschude deleted the fix-junit-5_9 branch January 9, 2023 20:19
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.

NoClassDefFoundError with junit jupiter 5.9
3 participants