You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Alexey Buistov <ja...@ua.fm> on 2004/11/22 10:57:38 UTC
Calling AbstractInstantiator.getInstance(Class) twice
Hello All,
I try to unit test my tapestry app using
org.apache.tapestry.test.AbstractInstantiator class posted somewhere in this
list a few weeks ago. The problem is when I invoke its method
getInstance(Class) more than once for the same class (class of my Tapestry
component) I get this error:
duplicate class definition: my/calendar/Vacation$enhance_0
java.lang.LinkageError: duplicate class definition:
my/calendar/Vacation$enhance_0
I think that Instantiator should _create_ enhanced classes like
Vacation$enhance_0, Vacation$enhance_1, Vacation$enhance_N and instantiate
them, _without_ throwing the exception...
Could someone point me to the solution for this problem? How should I use this
method? Maybe I'm misusing it?
Thanks,
Alexey
----
http://rabota.alkar.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Calling AbstractInstantiator.getInstance(Class) twice
Posted by Alexey Buistov <ja...@ua.fm>.
Just to make situation clearer: I noticed that LinkageError occurs only when I
have several testXXX methods, each of them invoking getInstance(). When
getInstance() is invoked several times in single test method, everything is
ok.
On Mon, 22 Nov 2004 11:57:38 +0200
"Alexey Buistov" <ja...@ua.fm> wrote:
> Hello All,
>
> I try to unit test my tapestry app using
> org.apache.tapestry.test.AbstractInstantiator class posted somewhere in this
> list a few weeks ago. The problem is when I invoke its method
> getInstance(Class) more than once for the same class (class of my Tapestry
> component) I get this error:
> duplicate class definition: my/calendar/Vacation$enhance_0
> java.lang.LinkageError: duplicate class definition:
> my/calendar/Vacation$enhance_0
>
> I think that Instantiator should _create_ enhanced classes like
> Vacation$enhance_0, Vacation$enhance_1, Vacation$enhance_N and instantiate
> them, _without_ throwing the exception...
> Could someone point me to the solution for this problem? How should I use
> this method? Maybe I'm misusing it?
>
> Thanks,
> Alexey
> ----
> http://rabota.alkar.net/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>
----
http://rabota.alkar.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org