Hi Karan,
I will give you the steps to follow. I just tried
running the tests and they run w/o any problem as per David's
instructions.
Like David Said you can run the test in openejb-core
org.apache.openejb.SomeoneBrokeSurefireAndThisIsADirtyHackForItTest
You need to give
-javaagent:C:\g\openejb3-trunk\container\openejb-javaagent\target\openejb-javaagent-3.0-incubating-SNAPSHOT.jar
in the Vm Arguments for JPA dynamic class file enhancement for
OpenJPA.
Note that we need to build the eclipse projects using mvn
eclipse:eclipse and import into your workspace before running the
tests.
This should get you going.
Regards
Manu
On 1/25/07, Karan Malhi <[EMAIL PROTECTED]> wrote:
Thanks David and Manu. Honestly, I dont understand the setup will enough to
even start looking in the right direction to try and fix this thing. For now
i will just work with mvn command line and delve into this when i understand
how the project is setup etc.
On 1/23/07, David Blevins <[EMAIL PROTECTED]> wrote:
>
> Great, yet another junit test runner that doesn't follow the junit
> rules :) There's a reason we have a class called
> SomeoneBrokeSurefireAndThisIsADirtyHackForItTest that particular
> junit runner doesn't run anything that isn't an immediate subclass of
> TestCase -- doesn't matter if your parent is a subclass of TestCase.
>
> I have no idea what it's going to take to get eclipse to call the
> junit static suite() method or what it will take. It took a bit of
> clever poking to see what surefire liked and didn't like.
>
> If all else fails, you can tell maven to run the test case with the
> remote debug port on (see the pom.xml for the openejb-core module)
> and use eclipse's remote debugger.
>
> /me wonders how great it would be if the junit guys wrote a
> compatibility test suite implementers of junit test runners could use
> to verify their implementations actually support the junit api.
>
> -David
>
> On Jan 23, 2007, at 2:09 PM, Karan Malhi wrote:
>
> > I ran it and it fails. Here is the failure trace
> >
> > junit.framework.AssertionFailedError: No tests found in
> > org.apache.openejb.SomeoneBrokeSurefireAndThisIsADirtyHackForItTest
> > at junit.framework.Assert.fail(Assert.java:47)
> > at junit.framework.TestSuite$1.runTest(TestSuite.java:93)
> > at junit.framework.TestCase.runBare(TestCase.java:130)
> > at junit.framework.TestResult$1.protect(TestResult.java:110)
> > at junit.framework.TestResult.runProtected(TestResult.java:128)
> > at junit.framework.TestResult.run(TestResult.java:113)
> > at junit.framework.TestCase.run(TestCase.java:120)
> > at junit.framework.TestSuite.runTest(TestSuite.java:228)
> > at junit.framework.TestSuite.run(TestSuite.java:223)
> > at org.junit.internal.runners.OldTestClassRunner.run(
> > OldTestClassRunner.java:35)
> > at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(
> > JUnit4TestReference.java:38)
> > at org.eclipse.jdt.internal.junit.runner.TestExecution.run(
> > TestExecution.java:38)
> > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
> > RemoteTestRunner.java:460)
> > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
> > RemoteTestRunner.java:673)
> > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(
> > RemoteTestRunner.java:386)
> > at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(
> > RemoteTestRunner.java:196)
> >
> >
> >
> > On 1/23/07, David Blevins <[EMAIL PROTECTED]> wrote:
> >>
> >> #openejb
> >> <ksmalhi> if i were to run openejb server from an ide, would
> >> the
> >> main
> >> class be org.apache.openejb.cli.Bootstrap ?
> >>
> >> The easiest thing to do is to ask your IDE to run this test case
> >>
> >> org.apache.openejb.SomeoneBrokeSurefireAndThisIsADirtyHackForItTest
> >>
> >> Use the one in the core package.
> >>
> >> Warning, if you use intellij it might lock up part way in due to some
> >> issue with OpenJPA we can't quite seem to figure out.
> >>
> >> -David
> >>
> >>
> >>
> >
> >
> > --
> > Karan Malhi
>
>
--
Karan Malhi