Bug 2092623 - Advance onboarding only when sync sign in completes #454 (firefox-autoland@autoland)

Warnings
  • Checking...
Blockers
  • Checking...
Branches bug2092623 -> autoland
Repo firefox-autoland@autoland (git) (git://github.com/corentinbect/firefox.git)
Author corentinbect
State closed
Commit Title

Bug 2092623 - Advance onboarding only when sync sign in completes

Commit Body

Selecting "Sign in" on the onboarding sync sign in card opened `TurnOnSyncFragment` and also called scrollToNextPageOrDismiss() immediately. This ran `OnboardingFragment.onFinish` before sign in had completed, but it returned early because `TurnOnSyncFragment` was the current destination. As soon as the account was connected, the sign in `LaunchedEffect` in `OnboardingScreen` called `OnboardingFragment.onFinish` another time, resulting in a delayed navigation to the home screen. This patch applies the same handling as bug 2092151. The sign in click no longer advances onboarding. Instead, `TurnOnSyncFragment` reports completion when it closes with an authenticated account and `SyncFlowCompletedEffect` moves to the next page once and consumes the result.

Landings

Successfully landed

Landing requested on , by cbect@mozilla.com.

Landing Job: 122098

Last update:

Result: 21b577bd7928ba2f33a3ad61b0a402c26b4dd9e6 on firefox-autoland@autoland (git)

Links: Treeherder