You can use directories to deploy to embedded EJB3. Here is an code example. Note that the standalone directory in the example is the parent directory of the deployment directory (i.e. standalone would contain a test subdirectory that would contain the deployment: META-INF, classes, etc.
URL deployDir = new URL("file:/C:/eclipse/workspace/jboss-head/ejb3/output/test-lib/embeddable/standalone"); EJB3StandaloneDeployer deployer = new EJB3StandaloneDeployer(); deployer.setKernel(EJB3StandaloneBootstrap.getKernel()); deployer.setJndiProperties(getInitialContextProperties()); deployer.setDefaultPersistenceProperties(getDefaultPersistenceProperties()); deployer.getDeployDirs().add(deployDir);
Thanks, in fact it works fine with classes. I had a problem in my classpath.
I'm sorry !!