Add unit tests for the event adapter