nsatragno | db7b65c64 | 2016-02-16 20:14:02 | [diff] [blame] | 1 | // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | #include "content/test/mock_background_sync_controller.h" |
| 6 | |
| 7 | namespace content { |
| 8 | |
| 9 | void MockBackgroundSyncController::NotifyBackgroundSyncRegistered( |
| 10 | const GURL& origin) { |
| 11 | registration_count_ += 1; |
| 12 | registration_origin_ = origin; |
| 13 | } |
| 14 | |
| 15 | void MockBackgroundSyncController::RunInBackground(bool enabled, |
| 16 | int64_t min_ms) { |
| 17 | run_in_background_count_ += 1; |
| 18 | run_in_background_enabled_ = enabled; |
| 19 | run_in_background_min_ms_ = min_ms; |
| 20 | } |
| 21 | |
| 22 | void MockBackgroundSyncController::GetParameterOverrides( |
| 23 | BackgroundSyncParameters* parameters) const { |
| 24 | *parameters = background_sync_parameters_; |
| 25 | } |
| 26 | |
| 27 | } // namespace content |