I got it to work. It isn't pretty but for running unit tests it is fine.
The solution was simple: I added the -javaagent: argument to the VM Arguments list. I used
a reference to the jboss-aop-jdk50.jar, but I made sure that this lib isn't within the
classpath.
I didn't try this before because I thought that the Embedded EJB3 already activated
this somehow. EJB3 Embedded itself uses AOP to do it's magic. But the library is
probably already aspectized.
The reason why i didn't add the jboss-aop-jdk50.jar to the classpath is because the
jboss-ejb3-all.jar already contains all the classes of AOP. This is off course the ugly
thing of it all. I don't know which version this jboss-ejb3-all.jar contains... I
still don't understand why someone ever created the jboss-ejb3-all.jar without
righting down which libraries it contains :(.
Before I used the jboss-aop-jdk50.jar I tried adding the right directives to the
jboss-ejb3-all.jar MANIFEST.MF file and use this lib as javaagent. But it threw Exceptions
and wouldn't start the VM.
But know everything works :D
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4042735#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...