Package org.apache.camel.test.cdi
Annotation Type Beans
-
@Documented @Inherited @Retention(RUNTIME) @Target(TYPE) public @interface Beans
Annotation to be used to customise the deployment configured by theCamelCdiRunner
.- See Also:
CamelCdiRunner
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description Class<?>[]
alternatives
Returns the list of alternatives to be selected in the application.Class<?>[]
classes
Returns the list of classes to be added as beans in the application.Class<?>[]
packages
Returns the list of classes whose packages are to be added for beans discovery.
-
-
-
Element Detail
-
alternatives
Class<?>[] alternatives
Returns the list of alternatives to be selected in the application. Note that the declared alternatives are globally selected for the entire application. For example, if you have the following named bean in your application:@Named("foo") public class FooBean { }
@Alternative @Named("foo") public class AlternativeBean { }
@Beans
annotation to you test class to activate it:@RunWith(CamelCdiRunner.class) @Beans(alternatives = AlternativeBean.class) public class TestWithAlternative { }
- See Also:
Alternative
- Default:
- {}
-
-
-
classes
Class<?>[] classes
Returns the list of classes to be added as beans in the application. That can be used to add classes to the deployment for test purpose in addition to the test class which is automatically added as bean.- Default:
- {}
-
-
-
packages
Class<?>[] packages
Returns the list of classes whose packages are to be added for beans discovery. That can be used to add packages to the deployment for test purpose in addition to the test class which is automatically added as bean.- Default:
- {}
-
-