I created a JPA test with an Arkillian (1.1.2 final) using the built-in Glassfish (3.1.2) and a test using EJBContainer in the same project. I can run the test one by one in Eclipse (Kepler) just fine (when I have Derby running in the background), but when I try to run tests using maven
'mvn clean test'
I get an error message:
Could not setup GlassFish Embedded Bootstrap
From surefire logs, I find this line:
Caused by: org.glassfish.embeddable.GlassFishException: Already bootstrapped
Now, if I comment out the test setup of the EJBC container, I can run the Arquillian test with maven.
The question is how to make the two test classes "independent" of each other so that the Arkillian does not crash due to the built-in container created using EJBContainer?
EJBC @AfterClass , .