Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Gemini » JUnit - GeminiJPARunner
JUnit - GeminiJPARunner [message #908390] Wed, 05 September 2012 09:52 Go to next message
Florian Pirchner is currently offline Florian Pirchner
Messages: 87
Registered: July 2009
Member

Hi,

yesterday evening i was writting a JUnitRunner for gemini JPA.

@RunWith(GeminiJPARunner.class)
@PersistenceUnits({ "org.lunifera.demo.persistence" })
public class ActivatorTest {


The testclass can be annotated with required persistence units. And the testrunner will wait, until the pus are available before running the test.
But it does not solve the "restart bundle" problem. Start orders have to be set too...

If it might be interesting for the project, i would contribute it to you.

Just give me a hint and i will attach it to a bug.

Best,
Florian
Re: JUnit - GeminiJPARunner [message #908492 is a reply to message #908390] Wed, 05 September 2012 13:29 Go to previous messageGo to next message
Michael Keith is currently offline Michael Keith
Messages: 215
Registered: July 2009
Senior Member
Hi Florian,

Thanks for the offer. We do have a simple framework and test runner (although it is not annotation driven) for Gemini JPA that does a similar thing, and also keeps track of test bundles that have been refreshed as a result of the persistence unit bundles refreshing, so tests are not executed multiple times. (See the 3 classes in org.eclipse.gemini.jpa.test.common). If you are interested in making it annotation driven, feel free, though Smile

Thanks,
-Mike
Re: JUnit - GeminiJPARunner [message #908511 is a reply to message #908492] Wed, 05 September 2012 13:57 Go to previous messageGo to next message
Florian Pirchner is currently offline Florian Pirchner
Messages: 87
Registered: July 2009
Member

Hi Mike,

i already had a look at it yesterday... But now i know why i should have
been using your approach. ;-)

Well, i will change my testrunner to meet your solution and add
annotation stuff to it. Put the solution to a bug as contribution.

Best,
Florian
Re: JUnit - GeminiJPARunner [message #908614 is a reply to message #908511] Wed, 05 September 2012 16:46 Go to previous message
Michael Keith is currently offline Michael Keith
Messages: 215
Registered: July 2009
Senior Member
Ok. Thanks, Florian.
Previous Topic:Gemini Blueprint 1.0.2.RELEASE
Next Topic:Exception Occurs when putting sample application of tomcat into Gemini Web
Goto Forum:
  


Current Time: Wed Oct 01 12:15:34 GMT 2014

Powered by FUDForum. Page generated in 0.02341 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software