Skip to content

first draft for custom element resolver (#518) #566

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

Closed
wants to merge 1 commit into from
Closed

first draft for custom element resolver (#518) #566

wants to merge 1 commit into from

Conversation

aaschmid
Copy link
Contributor

@aaschmid aaschmid commented Nov 11, 2016

Overview

To be able to provide a custom ElementResolver (#518), I tried some things and like this one quite well at the moment.

Details

It fits quite nice (IMHO) into the existing code / API by resolving the ExtensionRegistry earlier within the affected test descriptions (problem of mutability should be solved, though). This could also be more generalized by moving the new property up to JupiterTestDescription and add the current default element resolvers from DiscoverySelectorResolver to default extensions.

Disclaimer

The junit-dataprovider tests would already run using some quick and dirty implementation, see https://github.com/TNG/junit-dataprovider/compare/issue75-custom-junit5-element-resolver?expand=1
Also the test fixes are a bit hacky at the moment

Your opinion?

Does that go into the right direction? Or do you have something different in mind? What and why do you like / not like it (such that I can think of another solution)?

P.S.: This is just a first PoC / draft to discuss it more concrete ;-)


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

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
* also fixed tests even if some fixes are too hacky and need to be adjusted
@aaschmid
Copy link
Contributor Author

If I understand #506 correctly, it could be an alternative of solving this. Namely, by replacing some the element resolver with a custom one.

@aaschmid
Copy link
Contributor Author

aaschmid commented May 26, 2017

Seems that @TestTemplate (#14) is an alternative solution for this ...
=> closing this as according to @mmerdes this is not a desired solution anyways ...

@aaschmid aaschmid closed this May 26, 2017
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.

None yet

1 participant