Added tests for user authentication