Added more tests for the user and created a util class