[test] Adding tests to ensure that events are emitted