Added unit tests and event source.