public void testAsynchDeliveryTwice()
throws Exception
{
AsynchNotificationBroadcasterSupport broadcaster = new AsynchNotificationBroadcasterSupport();
Listener listener1 = new Listener();
broadcaster.addNotificationListener(listener1, null, null);
Listener listener2 = new Listener();
broadcaster.addNotificationListener(listener2, null, null);
clear();
createNotification(broadcaster);
compare(EMPTY, received(listener1, null));
compare(EMPTY, received(listener2, null));
listener1.doNotify(true);
listener1.doWait(false);
compare(sent, received(listener1, null));
compare(EMPTY, received(listener2, null));
listener2.doNotify(true);
listener2.doWait(false);
compare(sent, received(listener2, null));
}