In a jboss service I need to mock some inner class (not EJB) with JMockit. Just for tests I've created inner class ToBeMocked
and another one Mock. While deploying to jboss I get error NoClassDefFoundError
in line:
Mockit.setUpMock(ToBeMocked.class, new Mock());
with message:
java.lang.NoClassDefFoundError: mockit/Mockit
jmockit.jar
is added to the classpath in jboss_service.xml
.
Any ideas?