def test_is_authenticated(): user = User() assert not user.is_authenticated() user._session_token = 'invalid-session-token' assert not user.is_authenticated() user = User() user.set('username', 'user1_name') user.set('password', 'password') user.login() assert user.is_authenticated()
def test_is_authenticated(): user = User() assert not user.is_authenticated() user._session_token = "invalid-session-token" assert not user.is_authenticated() user = User() user.set("username", "user1_name") user.set("password", "password") user.login() assert user.is_authenticated()