| Index: content/browser/background_sync/background_sync_manager_unittest.cc
|
| diff --git a/content/browser/background_sync/background_sync_manager_unittest.cc b/content/browser/background_sync/background_sync_manager_unittest.cc
|
| index 3056594e8845bab0c02f8d65894a56be94ebbf45..22e3c76940c6c2f9b69477cfa681cf276a247ab0 100644
|
| --- a/content/browser/background_sync/background_sync_manager_unittest.cc
|
| +++ b/content/browser/background_sync/background_sync_manager_unittest.cc
|
| @@ -12,7 +12,6 @@
|
| #include "base/run_loop.h"
|
| #include "base/single_thread_task_runner.h"
|
| #include "base/thread_task_runner_handle.h"
|
| -#include "content/browser/background_sync/background_sync_network_observer.h"
|
| #include "content/browser/background_sync/background_sync_registration_handle.h"
|
| #include "content/browser/background_sync/background_sync_status.h"
|
| #include "content/browser/browser_thread_impl.h"
|
| @@ -232,9 +231,6 @@
|
| }
|
|
|
| void SetUp() override {
|
| - // Don't let the tests be confused by the real-world device connectivity
|
| - BackgroundSyncNetworkObserver::SetIgnoreNetworkChangeNotifierForTests(true);
|
| -
|
| helper_.reset(
|
| new EmbeddedWorkerTestHelper(base::FilePath(), kRenderProcessId));
|
|
|
| @@ -251,12 +247,6 @@
|
| // workers.
|
| base::RunLoop().RunUntilIdle();
|
| RegisterServiceWorkers();
|
| - }
|
| -
|
| - void TearDown() override {
|
| - // Restore the network observer functionality for subsequent tests
|
| - BackgroundSyncNetworkObserver::SetIgnoreNetworkChangeNotifierForTests(
|
| - false);
|
| }
|
|
|
| void RegisterServiceWorkers() {
|
| @@ -312,12 +302,7 @@
|
| void SetNetwork(net::NetworkChangeNotifier::ConnectionType connection_type) {
|
| net::NetworkChangeNotifier::NotifyObserversOfNetworkChangeForTests(
|
| connection_type);
|
| - if (test_background_sync_manager_) {
|
| - BackgroundSyncNetworkObserver* network_observer =
|
| - test_background_sync_manager_->GetNetworkObserverForTesting();
|
| - network_observer->NotifyManagerIfNetworkChanged(connection_type);
|
| - base::RunLoop().RunUntilIdle();
|
| - }
|
| + base::RunLoop().RunUntilIdle();
|
| }
|
|
|
| void SetOnBatteryPower(bool on_battery_power) {
|
|
|