-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
1.1.0.Final
-
None
This issue arises when tests running with Arquillian includes one or more @EJB objects as described below and running with the Glassfish remote container.
@RunWith(Arquillian.class)
public class GroupIntegrationTest {
@EJB
protected GroupService groupService;
// ..
}
First time all tests pass. But the second time: "javax.ejb.EJBException: null" on all tests (even thoose tests that are not defined in a test class with an @EJB).
I decide to delete the domain and create a new one. Testing again: all okey! next time: "javax.ejb.EJBException: null"..
The asadmin stop-domain and start-domain does not fix it ever. Same behaivor on 3.1.2. The only thing to do is to wipeout domain using delete-domain and create-domain and then start the tests..
The difference in the file tree after asadmin start-domain domain1 and after tests completed are shown below (where '+' sign is new files added).
domain1
│applications
│ └── __internal+
├── generated+
│ ├── ejb+
│ ├── jsp+
│ │ └── __default-web-module-server+
│ ├── policy+
│ │ └── __default-web-module+
│ │ └── __default-web-module+
│ │ └── granted.policy+
│ └── xml+
Hence, the domain directory is changed after running tests with Arquillian, and makes it very hard to perform regression tests since the domain must be deleted and recreated before every start of test suite.
Qualified guessing by aslak on irc:
[21:49] <aslak> 'maybe' some sync issue. e.g. gf return before it's completely undeployed and arq shuts it down or something