* @throws Exception
*/
public void testBeforeCompletion() throws Exception
{
ActionExecutorHome executorHome = (ActionExecutorHome) getInitialContext().lookup("ActionExecutorBean");
ActionExecutor executor = executorHome.create();
StatefulSessionHome sessionHome = (StatefulSessionHome) getInitialContext().lookup("StatefulSessionBean");
final StatefulSession session = sessionHome.create();
try
{
assertEquals("after-begin", executor.execute(new GetAfterBeginEntryAction(session.getHandle())));
assertEquals("before-completion", executor.execute(new GetBeforeCompletionEntryAction(session.getHandle())));
assertEquals("after-completion", executor.execute(new GetAfterCompletionEntryAction(session.getHandle())));
}
finally
{
if(session != null)
session.remove();