mirror of
https://github.com/discourse/discourse.git
synced 2025-05-25 19:29:34 +08:00
DEV: Fix failing 2FA tests
This commit is contained in:
@ -327,11 +327,15 @@ export default function() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return response({
|
return response({
|
||||||
error: "Invalid Second Factor",
|
failed: "FAILED",
|
||||||
|
ok: false,
|
||||||
|
error:
|
||||||
|
"Invalid authentication code. Each code can only be used once.",
|
||||||
reason: "invalid_second_factor",
|
reason: "invalid_second_factor",
|
||||||
backup_enabled: true,
|
backup_enabled: true,
|
||||||
sent_to_email: "eviltrout@example.com",
|
security_key_enabled: false,
|
||||||
current_email: "current@example.com"
|
totp_enabled: true,
|
||||||
|
multiple_second_factor_methods: false
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -341,11 +345,17 @@ export default function() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return response({
|
return response({
|
||||||
error: "Invalid Security Key",
|
failed: "FAILED",
|
||||||
reason: "invalid_security_key",
|
ok: false,
|
||||||
backup_enabled: true,
|
error:
|
||||||
sent_to_email: "eviltrout@example.com",
|
"The selected second factor method is not enabled for your account.",
|
||||||
current_email: "current@example.com"
|
reason: "not_enabled_second_factor_method",
|
||||||
|
backup_enabled: false,
|
||||||
|
security_key_enabled: true,
|
||||||
|
totp_enabled: false,
|
||||||
|
multiple_second_factor_methods: false,
|
||||||
|
allowed_credential_ids: ["allowed_credential_ids"],
|
||||||
|
challenge: "challenge"
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user