Added test cases to UserEnvironment class.