Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » AspectJ » Strange compilation/runtime problem
Strange compilation/runtime problem [message #566805] Tue, 13 May 2003 21:38
James Howe is currently offline James HoweFriend
Messages: 21
Registered: July 2009
Junior Member
I'm trying to build a simple extension to JUnit to simplify the writing of
some unit tests. I've created a subclass of the Standard JUnit TestCase
class and added some facilities to support virtual mock objects (the class
is a modification of one mentioned in the Virtual Mock Objects article).
Since I have a few other JUnit extensions, I've put the JUnit modifications
into their own Eclipse project. I've defined an aspect which interacts
with my JUnit extension, again based on the one from the article. The
JUnit project is *not* an AspectJ project, but the project containing the
aspect is. In Eclipse, I've configured my Aspect project to reference the
JUnit project. Using the 1.1.1 version of ADJT, both projects build just
fine. No errors. I built a third test project to hold some example code.
This project is also an AspectJ project. Using a very simple pointcut
definition which doesn't access my JUnit extensions, the aspect code runs
just fine. However, if I use the pointcut definition which accesses the
JUnit extensions, I get a run time exception telling me that a method on my
extension does not exist. I've made sure that everything is built and I
still get the exception. If I switch to the 1.1.2 version of AJDT I get a
compile error on my aspect complaining about the same method. Even though
the method is clearly defined in the code, the compiler complains about it
and I have found no way to make it work. I'm not sure whether this is a
bug, or just my misunderstanding of how things should work.

Any help on this matter would be greatly appreciated.

Thanks.

--
James Howe
Previous Topic:Strange compilation/runtime problem
Next Topic:AspectJ Error - ZipException Thrown
Goto Forum:
  


Current Time: Thu Mar 28 15:39:29 GMT 2024

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

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

Back to the top