Ok got it resolved pls ignore my prev mail
Regards
Manu
On 1/31/07, Manu George <[EMAIL PROTECTED]> wrote:
Hi,
I did some experimentation on this approach and came up with
the following problem.
Currently when the iTests are run for an application in the
openejb-core module, there is an application.xml which gets loaded
which has the element
<module>
<ejb>openejb-itests-beans-3.0-incubating-SNAPSHOT.jar</ejb>
</module>
So when I try to run the annotated beans in the module
openejb-itests-annotated-beans-3.0-incubating-SNAPSHOT.jar
by hiding the openejb-itests-beans I get an error saying the module
openejb-itests-beans-3.0-incubating-SNAPSHOT.jar cannot be loaded.
Is there any way to work around this?
Regards
Manu
On 1/24/07, Manu George <[EMAIL PROTECTED]> wrote:
> Yes thats a good idea. I had forgotten about this :). Let me look into
> creating a separate test suite for this
>
> Regards
> Manu
>
> On 1/24/07, David Blevins <[EMAIL PROTECTED]> wrote:
> > Following up in this thread as I need to plug in some annotation
> > based test into the itests as we are having some issues in the
> > Geronimo integration that are nearly impossible to get working or
> > ensure are working without actual annotations.
> >
> > We had discussed a separate test suite for annotated beans, which is
> > still a good idea. I plan to make a purely annotated version of our
> > jndi enc and field injection tests, I'll just put them in new classes
> > next to the other tests. We can move them out later if we want to go
> > ahead with the plan to test a completely ejb-jar.xml free set of itests.
> >
> >
> > -David
> >
> >
> > On Nov 26, 2006, at 6:48 PM, David Blevins wrote:
> >
> > > Hi Manu,
> > >
> > > On Nov 23, 2006, at 2:04 AM, Manu George wrote:
> > >
> > >> Hi David/Mohammad,
> > >>
> > >> What I was planning was to add annotated beans for each of the
> > >> corressponding beans deployed using the deployment descriptor. Then
> > >> execute all the test cases existing for the dd deployed beans for the
> > >> annotated beans as well.
> > >
> > > Sounds great.
> > >
> > >> In addition to this we need to create new
> > >> test cases for checking the overrides as well as the defaults(i.e.
> > >> beans with the very minimum annotations. The unpecified config
> > >> attributes should be substituted by defaults).
> > >
> > > Even with the override testing idea I posted before, we'll still
> > > want a few beans and tests, so this is still a good idea.
> > >
> > >> I was thinking that if we can deploy the annotated ejbs with
> > >> the same name as the dd based ones we can execute the existing tests
> > >> as well. We will have the beans and remote interfaces extending from
> > >> the existing ones as well.
> > >
> > > We don't have support for it yet, but we can use the mappedName
> > > attribute of the @Stateful, @Stateless, or @MessageDriven
> > > annotations to specify the OpenEJB deploymentId. We'll likely want
> > > to start using the mappedName of some of the other annotations as
> > > well. And we'll definitely want to document how we've allocated
> > > the "mappedName" attributes of various annotations on the website
> > > nice and clearly as it's vendor-specific. Maybe a table of some sort.
> > >
> > >> I plan to implement this by creating two new TestSuites
> > >> corressponding to iTest and RemoteiTest namely AnnotatediTest and
> > >> AnnotatedRemoteiTest. In iTest and RemoteiTest I will add the
> > >> following system property
> > >> System.setProperty("openejb.deployments.classpath.exclude",
> > >> ".*openejb-itests-annotated-beans.*");
> > >> This will prevent openejb from loading the descriptors in that
> > >> directory and so the annotated beans.Similarly if I set the property
> > >> to .*openejb-itests-beans.* in AnnotatediTests suite then the dd
> > >> based
> > >> beans won't be deployed. This will minimize the tests we need to
> > >> write
> > >> for annotated beans.
> > >
> > > Exactly what that's for! Though I'm beginning to think we should
> > > add an "openejb.deployments.classpath.include" as well. Is this
> > > something someone want's to add?
> > >
> > >> One issue I am not sure of here is even though we
> > >> will have annotated business interfaces in the jar deployed in server
> > >> the existing tests will use the parent interfaces only so we may need
> > >> to create some tests with annotated interfaces used at client side.
> > >
> > > I'm not sure out that will play out either. We should be able to
> > > get by, but there may be places we want tests dedicated to the
> > > annotated beans/interfaces.
> > >
> > >> Now I may have been missing something when i came up with
> > >> this approach and so it may not work. So I am looking for your
> > >> comments poiniting out the issues with this approach. Better
> > >> ideas,improvements and comments are welcome from anyone.
> > >
> > > You nailed it pretty well.
> > >
> > > One thing in general is that the field injection, setter injection,
> > > EJBContext.lookup (no JIRA for this yet), and JNDI ENC lookup tests
> > > are all going to doing pretty much the exact same things. It'd be
> > > best if they were all as similar as possible. We have a test for
> > > the JNDI ENC lookups on the types available in EJB 1.1 (needs to be
> > > updated for EJB3 also).
> > >
> > > http://svn.apache.org/repos/asf/incubator/openejb/trunk/openejb3/
> > > itests/openejb-itests-beans/src/main/java/org/apache/openejb/test/
> > > stateless/EncStatelessBean.java
> > > http://svn.apache.org/repos/asf/incubator/openejb/trunk/openejb3/
> > > itests/openejb-itests-client/src/main/java/org/apache/openejb/test/
> > > stateless/StatelessJndiEncTests.java
> > >
> > > This may or may not be useful as a launching pad for the new
> > > tests. We don't have to follow that style and we very well may
> > > want to rewrite that test to follow the style of the new tests if
> > > it turns out to be different.
> > >
> > > -David
> > >
> > >> Thanks
> > >> Manu
> > >>
> > >> On 11/20/06, David Blevins <[EMAIL PROTECTED]> wrote:
> > >>> On Nov 20, 2006, at 1:48 AM, Manu George wrote:
> > >>>
> > >>> > Hi David,
> > >>> > Have you created the beans that we are going to test
> > >>> > annotations? If not shall I go ahead and create the beans as
> > >>> extending
> > >>> > from the current test beans. I plan to create the session beans
> > >>> > required for testing the annotations you have implemented.
> > >>>
> > >>> Go for it!
> > >>>
> > >>> You can throw everything into an itests/openejb-itests-annotated-
> > >>> beans/ module.
> > >>>
> > >>> Note sure just yet how we'll wire it in to run with the other tests.
> > >>> If you have any ideas, I'm all ears.
> > >>>
> > >>> -David
> > >>>
> > >>>
> > >>>
> > >>>
> > >>
> > >
> >
> >
>