| Index: chrome/browser/push_messaging/background_budget_service_unittest.cc
|
| diff --git a/chrome/browser/push_messaging/background_budget_service_unittest.cc b/chrome/browser/push_messaging/background_budget_service_unittest.cc
|
| index 501602881cd4def8dce4a089004b1cf294094aac..75c34893bf5056227f33e8e679a9d1f329267d4e 100644
|
| --- a/chrome/browser/push_messaging/background_budget_service_unittest.cc
|
| +++ b/chrome/browser/push_messaging/background_budget_service_unittest.cc
|
| @@ -21,7 +21,7 @@ namespace {
|
|
|
| const char kTestOrigin[] = "https://example.com";
|
| const double kTestBudget = 10.0;
|
| -const double kTestSES = 24.0;
|
| +const double kTestSES = 48.0;
|
| const double kLowSES = 1.0;
|
| const double kMaxSES = 100.0;
|
| // Mirrors definition in BackgroundBudgetService, this is 10 days of seconds.
|
| @@ -184,11 +184,13 @@ TEST_F(BackgroundBudgetServiceTest, GetBudgetConsumedOverTime) {
|
| budget = service->GetBudget(origin);
|
|
|
| if (i % 10 == 0) {
|
| - service->StoreBudget(origin, budget - 1.0);
|
| + double cost = BackgroundBudgetService::GetCost(
|
| + BackgroundBudgetService::CostType::SILENT_PUSH);
|
| + service->StoreBudget(origin, budget - cost);
|
| }
|
| }
|
|
|
| - // With a SES of 24.0, the origin will get a budget of 2.4 per day, but the
|
| + // With a SES of 48.0, the origin will get a budget of 2.4 per day, but the
|
| // old budget will also decay. At the end, we expect the budget to be lower
|
| // than the starting budget.
|
| EXPECT_GT(budget, 0.0);
|
|
|