added tests for user model methods