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

Unified Diff: chrome/browser/profiles/profile_browsertest.cc

Issue 2711113003: Track whether a given user session has completed initialization, and use (Closed)
Patch Set: Added tests. Created 3 years, 10 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
Index: chrome/browser/profiles/profile_browsertest.cc
diff --git a/chrome/browser/profiles/profile_browsertest.cc b/chrome/browser/profiles/profile_browsertest.cc
index 2c689385873559b17e91004f91defeaf79c0f905..947bafe59e7d042cc4d554ac395dc0fde5dfe6df 100644
--- a/chrome/browser/profiles/profile_browsertest.cc
+++ b/chrome/browser/profiles/profile_browsertest.cc
@@ -346,6 +346,13 @@ IN_PROC_BROWSER_TEST_F(ProfileBrowserTest, CreateNewProfileSynchronous) {
std::unique_ptr<Profile> profile(CreateProfile(
temp_dir.GetPath(), &delegate, Profile::CREATE_MODE_SYNCHRONOUS));
CheckChromeVersion(profile.get(), true);
+
+#if defined(OS_CHROMEOS)
+ // Make sure session is marked as initialized.
+ user_manager::User* user =
+ chromeos::ProfileHelper::Get()->GetUserByProfile(profile.get());
+ EXPECT_TRUE(user->session_initialized());
+#endif
}
FlushIoTaskRunnerAndSpinThreads();
@@ -392,6 +399,12 @@ IN_PROC_BROWSER_TEST_F(ProfileBrowserTest,
// Wait for the profile to be created.
observer.Wait();
CheckChromeVersion(profile.get(), true);
+#if defined(OS_CHROMEOS)
+ // Make sure session is marked as initialized.
+ user_manager::User* user =
+ chromeos::ProfileHelper::Get()->GetUserByProfile(profile.get());
+ EXPECT_TRUE(user->session_initialized());
+#endif
}
FlushIoTaskRunnerAndSpinThreads();

Powered by Google App Engine
This is Rietveld 408576698