I was interrested in testing it so I checkouted your branch and tryed to install it localy. First I had the following error :
'dependencies.dependency.version' for org.jboss.shrinkwrap:shrinkwrap-extension-glassfish:jar is missing. @ line 43, column 19
I just added the version to pom.xml (1.0.0-alpha-12) and now I cannot install because the "IntegrationWarTestCase" fails on :
Failed tests:
shouldBeAbleToInjectEJBAsInstanceVariable(org.jboss.arquillian.container.glassfish.embedded_3_1.app.IntegrationWarTestCase)
It seems that the test case in error was not able to inject the referenced EJB :
@EJB
|
private NoInterfaceEJB bean;
|
|
@Test
|
public void shouldBeAbleToInjectEJBAsInstanceVariable() throws Exception
|
{
|
Assert.assertNotNull(
|
"Verify that the Bean has been injected",
|
bean);
|
|
Assert.assertEquals("Arquillian", bean.getName());
|
}
|
Having no clue why this could happend, I just installed it skipping the tests, and tried the installed snapshot on my project.
The sun-resources.xml is deployed correctly :
INFO: command add-resources result: PlainTextActionReporterSUCCESSDescription: add-resources AdminCommandnull
JDBC connection pool jdbc/wakwi-pool created successfully.
JDBC resource jdbc/wakwi-ds created successfully.
However ... I have the problem that the ejb is not injected in my test.
My test code :
@RunWith(Arquillian.class)
|
public class TestFileManagementServiceTest {
|
|
@Deployment
|
public static WebArchive createDeployment() {
|
return ShrinkWrap.create(WebArchive.class, "testFileManagementService.war").addClasses(
|
FileManagementService.class,
|
File.class,
|
Category.class,
|
FileStore.class,
|
CurrentFileStore.class,
|
DefaultFileStore.class).
|
addAsResource("test-persistence.xml", ArchivePaths.create("META-INF/persistence.xml")).
|
addAsResource(EmptyAsset.INSTANCE, "WEB-INF/beans.xml");
|
}
|
@EJB
|
private FileManagementService service;
|
|
@Test
|
public void testSaveFile() {
|
assertNotNull("Service should have been injected.", service);
|
}
|
}
|
Do you have the same problem injecting an EJB using the branch ARQ-397 ?
Is it related ?
Work started: https://github.com/aslakknutsen/arquillian/tree/ARQ-397
Need to figure out how to do individual Descriptor deploy/undeploy.