// Get JNDI Context
Context context = new InitialContext();
// Obtain
ImplementsSessionSynchronizationRemoteBusiness sfsb = (ImplementsSessionSynchronizationRemoteBusiness) context
.lookup(jndiName);
// Check callbacks are reset
this.assertCallbacksReset();
// Invoke
sfsb.call();
// Check callbacks have been made exactly once
this.assertCallsExpected(1);
// Invoke again
sfsb.call();
// Check callbacks have been made exactly twice
this.assertCallsExpected(2);
// Invoke again
sfsb.call();
// Check callbacks have been made exactly three times
this.assertCallsExpected(3);
// Reset