added event endpoint unit tests