Hi all ,
I am using Arquillian to develop integration tests for a project that I am currently working on. So far it went ok but now I am stuck with one problem. The problem is that a piece of code that I am trying to test is accessing some resources (which are in src/main/resources).
This project is a multimodule maven project and everything is packaged in an EAR.
For a test deployment I assemble an EAR from WARs and do some minor modifications like adding the test class into the right WAR and deleting some stuff. I know this maybe isn't the best way to do it but it was the most convenient for me. I am using JBoss AS 7 (7.1.0) as a server.
Needed resources are also in their place. Basically it is a directory that contains some files which need to be loaded. That directory is accessed by
URL url = Thread.currentThread().getContextClassLoader().getResource(directory);
When the files need to be loaded they are not loaded. The reason for this is probably the fact that the whole deployment is an archive file so the resources can't be accessed (right?).
So my questions are
I understand that without code it is hard to tell what is the problem so if needed I can create a small project to demonstrate the problem.
Thanks for your help