org.jboss.arquillian.test.spi.event.suite
Class TestLifecycleEvent

java.lang.Object
  extended by org.jboss.arquillian.test.spi.event.suite.SuiteEvent
      extended by org.jboss.arquillian.test.spi.event.suite.ClassEvent
          extended by org.jboss.arquillian.test.spi.event.suite.TestEvent
              extended by org.jboss.arquillian.test.spi.event.suite.TestLifecycleEvent
All Implemented Interfaces:
Event, LifecycleEvent
Direct Known Subclasses:
After, Before

public class TestLifecycleEvent
extends TestEvent
implements LifecycleEvent

A TestLifeCycleEvent is a type of TestEvent used for e.g. @Before/@After operations on the Test instance.

Version:
$Revision: $
Author:
Aslak Knutsen

Constructor Summary
TestLifecycleEvent(Object testInstance, Method testMethod)
          Create a new TestLifecycleEvent for a specific testInstance executing a specific testMethod.
TestLifecycleEvent(Object testInstance, Method testMethod, LifecycleMethodExecutor executor)
          Create a new TestLifecycleEvent for a specific testInstance executing a specific testMethod.
 
Method Summary
 LifecycleMethodExecutor getExecutor()
          Get the call back handler for this lifecycle method.
 
Methods inherited from class org.jboss.arquillian.test.spi.event.suite.TestEvent
getTestInstance, getTestMethod
 
Methods inherited from class org.jboss.arquillian.test.spi.event.suite.ClassEvent
getTestClass
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestLifecycleEvent

public TestLifecycleEvent(Object testInstance,
                          Method testMethod)
Create a new TestLifecycleEvent for a specific testInstance executing a specific testMethod.

This will use a NO_OP LifecycleMethodExecutor.

Parameters:
testInstance - The Test instance
testMethod - The Test Method being executed

TestLifecycleEvent

public TestLifecycleEvent(Object testInstance,
                          Method testMethod,
                          LifecycleMethodExecutor executor)
Create a new TestLifecycleEvent for a specific testInstance executing a specific testMethod.

Parameters:
testInstance - The Test instance
testMethod - The Test Method being executed
executor - A call back when the LifecycleMethod represented by this event should be invoked
Method Detail

getExecutor

public LifecycleMethodExecutor getExecutor()
Description copied from interface: LifecycleEvent
Get the call back handler for this lifecycle method.

Specified by:
getExecutor in interface LifecycleEvent
Returns:
the executor


Copyright © 2013 JBoss, a division of Red Hat, Inc.. All Rights Reserved.