Refactor; change authetication flow method
Add user model test