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

Make resolveContextLoader() method in AbstractTestContextBootstrapper protected [SPR-12682] #17281

Closed
spring-issuemaster opened this issue Feb 3, 2015 · 5 comments

Comments

Projects
None yet
2 participants
@spring-issuemaster
Copy link
Collaborator

commented Feb 3, 2015

Lari Hotari opened SPR-12682 and commented

I'm working on the Grails Unit test support and since Grails 3 is based on Spring Boot, the integration to Spring is tighter. We'd like to be able to reuse some parts of the Spring Test Context Framework in the Grails "Unit test runtime". The issue in Grails Jira is https://jira.grails.org/browse/GRAILS-11959 .

I've been designing the changes and it seems that we should be using the TestContext Framework's Bootstrap strategy to plug-in the Grails specific features. I'd like to be able to sub-class AbstractTestContextBootstrapper and override the resolveContextLoader method.


Affects: 4.1 GA

Issue Links:

  • #17282 Improve extensibility of TestContext bootstrap and context caching mechanisms

Referenced from: commits c006b74

@spring-issuemaster

This comment has been minimized.

Copy link
Collaborator Author

commented Feb 3, 2015

Lari Hotari commented

PR #731

@spring-issuemaster

This comment has been minimized.

Copy link
Collaborator Author

commented Apr 14, 2015

Sam Brannen commented

Completed as described in GitHub commit c006b74:

Make AbsTstCtxBootstrapper.resolveContextLoader protected

This commit increases the extensibility of
AbstractTestContextBootstrapper by making the resolveContextLoader()
and resolveExplicitContextLoaderClass() methods protected instead of
private.

Furthermore, resolveContextLoader() now throws an IllegalStateException
if getDefaultContextLoaderClass() returns null.

@spring-issuemaster

This comment has been minimized.

Copy link
Collaborator Author

commented Apr 14, 2015

Sam Brannen commented

Lari Hotari, please take a look at commit c006b74 and let me know if that is sufficient for your needs.

Thanks,

Sam

@spring-issuemaster

This comment has been minimized.

Copy link
Collaborator Author

commented Apr 15, 2015

Lari Hotari commented

Sam, looks good to me

@spring-issuemaster

This comment has been minimized.

Copy link
Collaborator Author

commented Apr 15, 2015

Sam Brannen commented

Great!

Thanks for the feedback,

Sam

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.