| Index: chrome/browser/profiles/profile_info_cache_unittest.cc
|
| diff --git a/chrome/browser/profiles/profile_info_cache_unittest.cc b/chrome/browser/profiles/profile_info_cache_unittest.cc
|
| index 571411501df6202e6bf58638e5e5fc9f24df01b3..5e110f65983a6ea4079d13ad179e4e5f0bdd9f4b 100644
|
| --- a/chrome/browser/profiles/profile_info_cache_unittest.cc
|
| +++ b/chrome/browser/profiles/profile_info_cache_unittest.cc
|
| @@ -9,6 +9,7 @@
|
| #include "base/prefs/testing_pref_service.h"
|
| #include "base/strings/stringprintf.h"
|
| #include "base/strings/utf_string_conversions.h"
|
| +#include "base/time/time.h"
|
| #include "chrome/browser/browser_process.h"
|
| #include "chrome/browser/chrome_notification_types.h"
|
| #include "chrome/browser/prefs/pref_service_syncable.h"
|
| @@ -307,6 +308,18 @@ TEST_F(ProfileInfoCacheTest, HasMigrated) {
|
| EXPECT_FALSE(GetCache()->GetHasMigratedToGAIAInfoOfProfileAtIndex(1));
|
| }
|
|
|
| +TEST_F(ProfileInfoCacheTest, ProfileActiveTime) {
|
| + GetCache()->AddProfileToCache(
|
| + GetProfilePath("path_1"), ASCIIToUTF16("name_1"),
|
| + base::string16(), 0, std::string());
|
| + EXPECT_EQ(base::Time(), GetCache()->GetProfileActiveTimeAtIndex(0));
|
| + base::Time before = base::Time::Now();
|
| + GetCache()->SetProfileActiveTimeAtIndex(0);
|
| + base::Time after = base::Time::Now();
|
| + EXPECT_LE(before, GetCache()->GetProfileActiveTimeAtIndex(0));
|
| + EXPECT_GE(after, GetCache()->GetProfileActiveTimeAtIndex(0));
|
| +}
|
| +
|
| TEST_F(ProfileInfoCacheTest, GAIAName) {
|
| GetCache()->AddProfileToCache(
|
| GetProfilePath("path_1"), ASCIIToUTF16("name_1"),
|
|
|