Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(54)

Issue 2577903002: cros: Fix inconsistent SessionController state for tests (Closed)

Created:
4 years ago by xiyuan
Modified:
4 years ago
Reviewers:
Alexander Alekseev
CC:
chromium-reviews, alemate+watch_chromium.org, achuith+watch_chromium.org, oshima+watch_chromium.org, davemoore+watch_chromium.org, James Cook
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

cros: Fix inconsistent SessionController state for tests - Do not set ACTIVE state in StartRestoreAfterCrashSession and StartStubLoginSession. SessionStarted() call will do that. Setting it explicitly breaks tests such as AccessibilityManagerTest that has "--login-manager" but goes through StartRestoreAfterCrashSession code to initialize; - CrashRestoreComplexTest should use GetLRULoggedInUsers instead of GetLoggedInUsers since it tests the user session order; - Fix UserManagerBase to cover tests that add a non-existent user; - Make sure |logged_in_user_| preserves the order since its index is used as fake session id ATM; - Fire UserAddedToSession for such users; BUG=648964 TEST=Existing tests. Committed: https://crrev.com/8cb43c2a16b3341a3940b7919a8b61a4b93f2998 Cr-Commit-Position: refs/heads/master@{#438944}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+7 lines, -9 lines) Patch
M chrome/browser/chromeos/login/crash_restore_browsertest.cc View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/chromeos/login/session/chrome_session_manager.cc View 2 chunks +0 lines, -6 lines 0 comments Download
M components/user_manager/user_manager_base.cc View 1 chunk +6 lines, -2 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 14 (9 generated)
xiyuan
alemate, please review the change. This is needed for James' https://codereview.chromium.org/2573703003/. Thanks.
4 years ago (2016-12-14 23:39:44 UTC) #2
Alexander Alekseev
lgtm
4 years ago (2016-12-15 22:43:33 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2577903002/1
4 years ago (2016-12-15 22:46:10 UTC) #9
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years ago (2016-12-15 22:59:59 UTC) #12
commit-bot: I haz the power
4 years ago (2016-12-15 23:03:21 UTC) #14
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/8cb43c2a16b3341a3940b7919a8b61a4b93f2998
Cr-Commit-Position: refs/heads/master@{#438944}

Powered by Google App Engine
This is Rietveld 408576698