Annotation Type TargetsContainer
@Documented
@Retention(RUNTIME)
@Target({METHOD,FIELD,PARAMETER})
public @interface TargetsContainer
When using multiple containers within the same test suite, you can use the @TargetsContainer annotation to specify
which container a deployment should be deployed to.
Usage Example:
@Deployment @TargetsContainer("X")
public static WebArchive create() {
return ShrinkWrap.create(WebArchive.class);
}
@Deployment
public static WebArchive create() {
return ShrinkWrap.create(WebArchive.class)
}
The TargetsContainer name refers to the container qualifier defined in the Arquillian configuration.
<?xml version="1.0" encoding="UTF-8"?>
<arquillian xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://jboss.org/schema/arquillian"
xsi:schemaLocation="http://jboss.org/schema/arquillian http://jboss.org/schema/arquillian/arquillian_1_0.xsd">
<group qualifier="G">
<container qualifier="X" />
<container qualifier="Y" default="true" />
</group>
</arquillian>
If a container is defined as default=true in configuration, the @TargetsContainer annotation can be emitted when targeting that container. Only one container can be set as default within a group.
- Version:
- $Revision: $
- Author:
- Aslak Knutsen
-
Required Element Summary
Required Elements
-
Element Details
-
value
String valueThe name of the target container as defined in configuration.- Returns:
- The target name.
-