-
1. Re: Arquillian and alternatives in CDI
aslak Oct 6, 2013 12:48 AM (in response to fleurystephane)normally WEB-INF is not a ClassLoader resource.
Try using war.addAsWebInfResource(new File("src/main/webapp/WEB-INF/beans.xml")) instead
-
2. Re: Arquillian and alternatives in CDI
fleurystephane Oct 6, 2013 3:18 AM (in response to aslak)Thanks for your answer!
I already tried this issue but it doesn't work.I put my project here : https://bitbucket.org/fleurystephane/footballfederation
I commented the Arquillian test to make sure the project (the WebService) is working correctly.
Question : when you use
war.addAsWebInfResource(new File("src/main/webapp/WEB-INF/beans.xml"))
you don't use the real project file, so it is not a real test ..., isn't it?
Stéphane
-
3. Re: Arquillian and alternatives in CDI
aslak Oct 6, 2013 7:02 AM (in response to fleurystephane)Here's a pull request: https://bitbucket.org/fleurystephane/footballfederation/pull-request/1/fix-failing-test/diff
There is actually some issue with the use of EJB's in the Weld EE Embedded Mock container. It's designed for CDI only. While Weld SE Embedded Container will allow to create EJB's as CDI beans (no EJB features just plain simple CDI), the Weld EE Container seems to have some issues.
-
4. Re: Arquillian and alternatives in CDI
fleurystephane Oct 6, 2013 7:34 AM (in response to aslak)Thanks a lot Aslak!
I've to test my SOAP Service, for now I use SoapUI. Is there another way to run integration test for Jax-WS WebServices ?
Stéphane
-
5. Re: Arquillian and alternatives in CDI
aslak Oct 6, 2013 8:49 AM (in response to fleurystephane)1 of 1 people found this helpfulWe don't have any specific support around Jax-WS WebServices, but you can use Soap-UI with Arquillian.
The "Arquillian Testing Guide" book has an example on that;
Basically it is;
* Use a container that supports Jax-WS
* Test it as a Client using @Deployment.testable=false
* Inject the URL to the deployment using @ArquillianResource URL;
* Create a new instance of the SoapUITestRunner given the URL in the @Test method.
-
6. Re: Arquillian and alternatives in CDI
fleurystephane Oct 6, 2013 11:43 AM (in response to aslak)OK, Thanks for all