Dispatcher dispatcher = DispatcherFactory.newDispatcher(1,
new ThreadPoolExecutor.AbortPolicy(),"test");
Assert.assertNotNull(dispatcher);
final CountDownLatch latch = new CountDownLatch(1);
final AtomicInteger count = new AtomicInteger();
dispatcher.dispatch(new Runnable() {
public void run() {
count.incrementAndGet();
latch.countDown();
}
});