def test_user_service_auth_user_success(): clean_env() user_service = UserService(user_catalog, user_db) user_service.try_reg_user("admin", "admin1234") assert user_service.auth_user("admin", "admin1234") is True clean_env()
def test_user_service_auth_user_fail(): clean_env() user_service = UserService(user_catalog, user_db) user_service.try_reg_user("admin", "admin") assert user_service.auth_user("admin", "bad_pass") is False clean_env()