added few helper functions in test class