Class DisposalMethodDefinitionTest
- java.lang.Object
-
- org.jboss.arquillian.testng.Arquillian
-
- org.jboss.cdi.tck.AbstractTest
-
- org.jboss.cdi.tck.tests.implementation.disposal.method.definition.DisposalMethodDefinitionTest
-
- All Implemented Interfaces:
org.testng.IHookable,org.testng.ITestNGListener
@SpecVersion(spec="cdi", version="2.0") public class DisposalMethodDefinitionTest extends AbstractTest
-
-
Field Summary
-
Fields inherited from class org.jboss.cdi.tck.AbstractTest
beanManager
-
-
Constructor Summary
Constructors Constructor Description DisposalMethodDefinitionTest()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static org.jboss.shrinkwrap.api.spec.WebArchivecreateTestArchive()voidtestBindingTypesAppliedToDisposalMethodParameters()voidtestDisposalMethodCalledForProducerField()Tests that a disposal method can be bound to a product of a producer field.voidtestDisposalMethodForMultipleProducerMethods()voidtestDisposalMethodOnNonBean()voidtestDisposalMethodParametersGetInjected()In addition to the disposed parameter, a disposal method may declare additional parameters, which may also specify bindings.-
Methods inherited from class org.jboss.cdi.tck.AbstractTest
activate, annotationSetMatches, annotationSetMatches, destroyContext, getBeans, getBeans, getContextualReference, getContextualReference, getContextualReference, getCurrentBeanContainer, getCurrentConfiguration, getCurrentManager, getUniqueBean, getUniqueBean, isThrowablePresent, newDependentInstance, passivate, rawTypeSetMatches, setContextActive, setContextInactive, typeSetMatches
-
-
-
-
Method Detail
-
createTestArchive
@Deployment public static org.jboss.shrinkwrap.api.spec.WebArchive createTestArchive()
-
testBindingTypesAppliedToDisposalMethodParameters
@SpecAssertion(section="method_constructor_parameter_qualifiers",id="c") @SpecAssertion(section="disposer_method",id="b") @SpecAssertion(section="disposer_method",id="c") @SpecAssertion(section="disposer_method",id="e") @SpecAssertion(section="disposer_method_disposed_parameter",id="ba") @SpecAssertion(section="declaring_disposer_method",id="a") @SpecAssertion(section="declaring_disposer_method",id="ba") @SpecAssertion(section="disposer_method_resolution",id="aa") @SpecAssertion(section="producer_or_disposer_methods_invocation",id="b") public void testBindingTypesAppliedToDisposalMethodParameters() throws Exception- Throws:
Exception
-
testDisposalMethodOnNonBean
@SpecAssertion(section="disposer_method",id="aa") @SpecAssertion(section="disposer_method_disposed_parameter",id="ba") public void testDisposalMethodOnNonBean() throws Exception- Throws:
Exception
-
testDisposalMethodParametersGetInjected
@SpecAssertion(section="declaring_disposer_method",id="h") @SpecAssertion(section="injection_point_default_qualifier",id="a") @SpecAssertion(section="producer_or_disposer_methods_invocation",id="e") public void testDisposalMethodParametersGetInjected() throws ExceptionIn addition to the disposed parameter, a disposal method may declare additional parameters, which may also specify bindings. The container calls Manager.getInstanceToInject() to determine a value for each parameter of a disposal method and calls the disposal method with those parameter values- Throws:
Exception
-
testDisposalMethodForMultipleProducerMethods
@SpecAssertion(section="disposer_method_disposed_parameter", id="da") public void testDisposalMethodForMultipleProducerMethods() throws Exception- Throws:
Exception
-
testDisposalMethodCalledForProducerField
@SpecAssertion(section="disposer_method_resolution",id="ab") @SpecAssertion(section="producer_field_lifecycle",id="o") public void testDisposalMethodCalledForProducerField() throws ExceptionTests that a disposal method can be bound to a product of a producer field. CDI-145- Throws:
Exception
-
-