move event printing code into separate class
add failing mockito based test