Skip to main content


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 PirchnerFriend
Messages: 94
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 KeithFriend
Messages: 243
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 PirchnerFriend
Messages: 94
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 messageGo to next message
Michael Keith is currently offline Michael KeithFriend
Messages: 243
Registered: July 2009
Senior Member
Ok. Thanks, Florian.
Re: JUnit - GeminiJPARunner [message #1725013 is a reply to message #908614] Mon, 29 February 2016 07:37 Go to previous message
Marco Descher is currently offline Marco DescherFriend
Messages: 197
Registered: October 2010
Location: Austria
Senior Member
I am having a lot of troubles getting a Gemini JUnit 4 Plug-in Test to run. I described the case in https://bugs.eclipse.org/bugs/show_bug.cgi?id=488665 ...

as soon as I add org.eclipse.gemini.jpa to the Junit plug-in activating it, I hit an NPE and the test fails.

I still seem to have some problems understanding the way this works. What is the state of GeminiJPARunner, is it somewhere available??
thanks!
Previous Topic:Gemini JPA 1.2.0 M1 milestone available
Next Topic:[Gemini Blueprint] Keep Getting Failed to load class org.slf4j.impl.StaticLoggerBinder
Goto Forum:
  


Current Time: Tue Apr 23 16:48:10 GMT 2024

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

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

Back to the top