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

Add CDI support into the project #9

Closed
jonbullock opened this issue Apr 24, 2013 · 6 comments
Closed

Add CDI support into the project #9

jonbullock opened this issue Apr 24, 2013 · 6 comments

Comments

@jonbullock
Copy link
Member

Add CDI support into the project, maybe using Weld?

@ghost ghost assigned jonbullock Apr 24, 2013
@s17t
Copy link
Contributor

s17t commented Oct 8, 2013

Similar thing can be achieved with spring-core and spring-context and with 3.2 version no XML have to hurt.

@jonbullock
Copy link
Member Author

Thanks for the suggestion, Spring will also be investigated.

@rajmahendra
Copy link

If we plan to use CDI for plain JUnit testcase is not good we need to use Arquillian

@jonbullock
Copy link
Member Author

Thanks Raj, I'm not sure whether CDI support is required at the moment.

I'll leave this open for the time being but won't do anything with it until we identify a real need for it.

@RainerW
Copy link
Contributor

RainerW commented Jan 5, 2014

Did add weld : https://github.com/jonbullock/JBake/pull/72

@s17t Normally i use Spring. The pull request only uses annotations from javax.inject.* , changing the framework should be possible. Spring could be interresting when using a kind of Store like https://github.com/jonbullock/JBake/pull/68 , because the spring-data abstractions are quite awsome!

@jonbullock Yes, CDI support was necessary, ConfigUtil has a static reset() method ...

@rajmahendra Depends on your test level. Haven't used Arquillian. But for just plain unit testing using Mockito with it's inject mock logic (http://docs.mockito.googlecode.com/hg/org/mockito/InjectMocks.html) should work just fine and doesn't need a runner.

@jonbullock
Copy link
Member Author

@RainerW thanks for the tip on injection in Mockito, very useful to know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants