modified the unit test code to adopt with the changes in Event class