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

Unified Diff: components/user_manager/user_unittest.cc

Issue 2711113003: Track whether a given user session has completed initialization, and use (Closed)
Patch Set: Only expose known_user::RemovePrefsForTesting() for tests Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « components/user_manager/user_manager_base.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/user_manager/user_unittest.cc
diff --git a/components/user_manager/user_unittest.cc b/components/user_manager/user_unittest.cc
index 05f563f5d2dc4d13ce564f7d9f5a511db63f0047..eb3ca8bfcaadbeeabeb08c4a133d28c9b0932224 100644
--- a/components/user_manager/user_unittest.cc
+++ b/components/user_manager/user_unittest.cc
@@ -44,4 +44,12 @@ TEST(UserTest, DeviceLocalAccountAffiliation) {
EXPECT_TRUE(arc_kiosk_user.IsAffiliated());
}
+TEST(UserTest, UserSessionInitialized) {
+ const AccountId account_id = AccountId::FromUserEmailGaiaId(kEmail, kGaiaId);
+ std::unique_ptr<User> user(User::CreateRegularUser(account_id));
+ EXPECT_FALSE(user->profile_ever_initialized());
+ user->set_profile_ever_initialized(true);
+ EXPECT_TRUE(user->profile_ever_initialized());
+}
+
} // namespace user_manager
« no previous file with comments | « components/user_manager/user_manager_base.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698