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

Unified Diff: chrome/browser/banners/app_banner_settings_helper_unittest.cc

Issue 2379783002: Instant App Banner logic. (Closed)
Patch Set: Fixing tests. Created 4 years, 2 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 | « chrome/browser/banners/app_banner_settings_helper.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/banners/app_banner_settings_helper_unittest.cc
diff --git a/chrome/browser/banners/app_banner_settings_helper_unittest.cc b/chrome/browser/banners/app_banner_settings_helper_unittest.cc
index 7f4a9840c8a23904edd5895aa1f1144f76277385..fe1756f8d2510db875a043095780d6fa37304bd7 100644
--- a/chrome/browser/banners/app_banner_settings_helper_unittest.cc
+++ b/chrome/browser/banners/app_banner_settings_helper_unittest.cc
@@ -657,7 +657,7 @@ TEST_F(AppBannerSettingsHelperTest, ShouldNotShowAfterShowing) {
base::Time reference_time = GetReferenceTime();
base::Time one_day_ago = reference_time - base::TimeDelta::FromDays(1);
- base::Time three_weeks_ago = reference_time - base::TimeDelta::FromDays(21);
+ base::Time one_week_ago = reference_time - base::TimeDelta::FromDays(7);
base::Time one_year_ago = reference_time - base::TimeDelta::FromDays(366);
// By default the banner should not be shown.
@@ -687,7 +687,7 @@ TEST_F(AppBannerSettingsHelperTest, ShouldNotShowAfterShowing) {
// Show the site more recently. Now it should not be shown.
AppBannerSettingsHelper::RecordBannerEvent(
web_contents(), url, kTestPackageName,
- AppBannerSettingsHelper::APP_BANNER_EVENT_DID_SHOW, three_weeks_ago);
+ AppBannerSettingsHelper::APP_BANNER_EVENT_DID_SHOW, one_week_ago);
EXPECT_EQ(PREVIOUSLY_IGNORED,
AppBannerSettingsHelper::ShouldShowBanner(
web_contents(), url, kTestPackageName, reference_time));
« no previous file with comments | « chrome/browser/banners/app_banner_settings_helper.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698