feat(accountsetup): add Yahoo app-password/2FA help in onboarding
Yahoo's guided app-password setup pointed appPasswordHelpUrl at the generic account-security sign-in page, which assumes the user already knows to hunt for "Create app password" once there. Point it instead at Yahoo's own step-by-step "Generate and manage 3rd-party app passwords" article, mirroring what #153 did for iCloud. Yahoo does NOT gate app-password creation behind two-step verification (verified against Yahoo's live help docs, which never list it as a prerequisite), so — unlike Gmail and iCloud — it keeps twoFactorHelpUrl null and shows no 2FA button. AppPasswordSetupScreen already renders the help buttons generically from these provider fields, so no screen change is needed; the existing PR #152 ordering (2FA link before the app-password link) is preserved for the providers that have both. Add a MailProviderTest assertion pinning Yahoo's new app-password URL (mirroring the iCloud test) and extend the onboarding yahooSetup_hasNoTwoFactorHelpLink coverage note for #155. Closes #155 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -254,10 +254,11 @@ class OnboardingFlowTest {
|
||||
waitForText("Yahoo Mail")
|
||||
composeTestRule.onNodeWithText("Yahoo Mail").performClick()
|
||||
|
||||
// Yahoo's setup screen keeps its app-password link…
|
||||
// Yahoo's setup screen keeps its app-password link (now pointing at Yahoo's step-by-step
|
||||
// instructions article instead of the generic account-security page, issue #155)…
|
||||
waitForText(string(R.string.app_password_open_page, "Yahoo Mail"))
|
||||
// …but gains no two-factor help link: unlike Gmail and iCloud, Yahoo gates nothing on it
|
||||
// (issue #98, #153).
|
||||
// (issue #98, #153, #155).
|
||||
composeTestRule.onNodeWithText(string(R.string.app_password_2fa_help)).assertDoesNotExist()
|
||||
composeTestRule.onNodeWithText(string(R.string.app_password_2fa_help_icloud)).assertDoesNotExist()
|
||||
}
|
||||
|
||||
@@ -64,7 +64,12 @@ enum class MailProvider(
|
||||
YAHOO(
|
||||
key = "yahoo",
|
||||
displayName = "Yahoo Mail",
|
||||
appPasswordHelpUrl = "https://login.yahoo.com/account/security",
|
||||
// Yahoo's own step-by-step "Generate and manage 3rd-party app passwords" article, not
|
||||
// just the generic account-security sign-in page — that page assumes the user already
|
||||
// knows to look for "Create app password" once there (issue #155). Unlike Gmail/iCloud,
|
||||
// this article never lists two-step verification as a prerequisite for generating an app
|
||||
// password, so there is no twoFactorHelpUrl below.
|
||||
appPasswordHelpUrl = "https://my.help.yahoo.com/kb/mail/generate-app-specific-password-sln15241.html",
|
||||
imapHost = "imap.mail.yahoo.com",
|
||||
smtpHost = "smtp.mail.yahoo.com",
|
||||
// Yahoo documents smtp.mail.yahoo.com:465 with implicit SSL/TLS as its outgoing server.
|
||||
|
||||
@@ -96,7 +96,9 @@ class MailProviderTest {
|
||||
// generic Apple ID sign-in page (issue #153).
|
||||
assertEquals("https://support.apple.com/en-us/102660", MailProvider.ICLOUD.twoFactorHelpUrl)
|
||||
|
||||
// Yahoo gates nothing on two-factor, so it must not grow the extra link.
|
||||
// Yahoo gates nothing on two-factor — reconfirmed directly against Yahoo's own help docs,
|
||||
// which never list two-step verification as a prerequisite for generating an app password
|
||||
// (issue #155) — so it must not grow the extra link.
|
||||
assertNull(MailProvider.YAHOO.twoFactorHelpUrl)
|
||||
}
|
||||
|
||||
@@ -105,6 +107,14 @@ class MailProviderTest {
|
||||
assertEquals("https://support.apple.com/en-us/102654", MailProvider.ICLOUD.appPasswordHelpUrl)
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `yahoo app-password help points at Yahoo's step-by-step instructions, not the generic sign-in page`() {
|
||||
assertEquals(
|
||||
"https://my.help.yahoo.com/kb/mail/generate-app-specific-password-sln15241.html",
|
||||
MailProvider.YAHOO.appPasswordHelpUrl,
|
||||
)
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `createAccount trims the email and derives a stable id and display name`() {
|
||||
val account = MailProvider.GMAIL.createAccount(" User@Gmail.com ")
|
||||
|
||||
Reference in New Issue
Block a user