@Test
    public void testVerifyMessages() {
        MockHandler handler = new MockHandler();
        LogDispatcher dispatcher = new LogDispatcher();
        dispatcher.registerLogHandler(handler);

        dispatcher.handle(sample1);
        dispatcher.handle(sample2);

        assertTrue(sample1 == handler.messages.get(0));
        assertTrue(sample2 == handler.messages.get(1));
    }
Unit tests for thge LogMessage class.

@author Bjorn Borud
logserver/src/test/java/com/yahoo/logserver/test/LogDispatcherTestCase.java