SystemAtomicComponent atomicContext = createContext(scopeContext);
Object session1 = new Object();
workContext.setIdentifier(HttpSessionScopeContainer.HTTP_IDENTIFIER, session1);
SessionScopeInitDestroyComponent o1 =
(SessionScopeInitDestroyComponent) scopeContext.getInstance(atomicContext);
assertTrue(o1.isInitialized());
Object session2 = new Object();
workContext.setIdentifier(HttpSessionScopeContainer.HTTP_IDENTIFIER, session2);
SessionScopeInitDestroyComponent o2 =
(SessionScopeInitDestroyComponent) scopeContext.getInstance(atomicContext);
assertNotSame(o1, o2);
scopeContext.onEvent(new HttpSessionEnd(this, session1));
assertTrue(o1.isDestroyed());
assertFalse(o2.isDestroyed());
scopeContext.onEvent(new HttpSessionEnd(this, session2));
assertTrue(o2.isDestroyed());
scopeContext.stop();
}