userSvc testing and refactor