Java Reference
In-Depth Information
Running Arquillian TicketTest
It's possible to run Arquillian tests both from Maven and your IDE. You have to remember
that we declared the container adapter in the Maven profile, so in order to run the full build,
you have to run the following command line:
mvn clean package -Parquillian-wildfly-managed
If you want to run the test from Eclipse, you have to navigate to the project properties and
select the Maven property. In the Active Maven Profiles field, enter arquillian-
wildfly-managed (as shown in the following screenshot), which we declared earlier in
the pom.xml file:
Now all you have to do is right-click on your TicketServiceTest class and select
Run As JUnit Test . The Arquillian engine will start, producing the outcome of the test in
the JUnit view (you can make it visible by navigating to Menu | Window | Show View |
JUnit ).
Congratulations! The JUnit console accounts for the first test that was run successfully.
If you want to use only one container in your test, then a good idea would be to set the de-
fault Maven profile, by adding the following lines to it in the pom.xml file:
Search WWH ::

Custom Search