Talk:APISeam
From APIDesign
(Difference between revisions)
(Comment provided by evanx - via ArticleComments extension) |
|||
Line 22: | Line 22: | ||
--[http://www.jroller.com/berni/ Bernhard] 00:40, 13 January 2009 (CET) | --[http://www.jroller.com/berni/ Bernhard] 00:40, 13 January 2009 (CET) | ||
</div> | </div> | ||
+ | |||
+ | Thanks for your question Bernhard. The magic is hidden in the <source lang="java">MockServices.setServices(Class...)</source> call. It generates appropriate META-INF/services/ files on the fly and as such the results returned from <source lang="java">ServiceLoader.load(...).iterator()</source> can be different at different time of test execution. In case you need this functionality, feel free to use [[NbJUnit]]. | ||
+ | |||
+ | --[[User:JaroslavTulach|JaroslavTulach]] 21:21, 15 January 2009 (UTC) | ||
+ | |||
== evanx said ... == | == evanx said ... == | ||
Line 29: | Line 34: | ||
--evanx 10:37, 13 January 2009 (CET) | --evanx 10:37, 13 January 2009 (CET) | ||
</div> | </div> | ||
+ | |||
+ | That is indeed good option in case you believe that the submitted idea is sane. If you do not trust that, [[CodeInjection]] is better than saying ''no'' to the patch. | ||
+ | |||
+ | --[[User:JaroslavTulach|JaroslavTulach]] 21:21, 15 January 2009 (UTC) |
Revision as of 21:21, 15 January 2009
Comments on CodeInjection <comments />
Varun said ...
Bernhard said ...
I have question:
Do you see any problems to run both tests testDecrementFourTimes, and testDecrementTwoTimesEnough in the same JVM?
How do you make the ServiceLoader unaware of the CountDownExtender when running the testDecrementFourTimes method?
--Bernhard 00:40, 13 January 2009 (CET)
MockServices.setServices(Class...)
ServiceLoader.load(...).iterator()
--JaroslavTulach 21:21, 15 January 2009 (UTC)
evanx said ...
can't you "mentor" the submitters with some constructive feedback, requesting some refactoring
--evanx 10:37, 13 January 2009 (CET)
That is indeed good option in case you believe that the submitted idea is sane. If you do not trust that, CodeInjection is better than saying no to the patch.
--JaroslavTulach 21:21, 15 January 2009 (UTC)
Nice blog :)
--Varun 06:54, 11 January 2009 (CET)