Added unit tests for event callbacks