added event module and tests