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

Unified Diff: chrome/browser/chromeos/drive/drive_sync_client_unittest.cc

Issue 11620007: Switch from OnIPAddressChanged and OnConnectionTypeChange to OnNetworkChanged Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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
Index: chrome/browser/chromeos/drive/drive_sync_client_unittest.cc
diff --git a/chrome/browser/chromeos/drive/drive_sync_client_unittest.cc b/chrome/browser/chromeos/drive/drive_sync_client_unittest.cc
index c5b5be148303bcd9269610b398afdffc962e2bb7..72d2cd09b32520e013a4fcb579d0be16a3a85041 100644
--- a/chrome/browser/chromeos/drive/drive_sync_client_unittest.cc
+++ b/chrome/browser/chromeos/drive/drive_sync_client_unittest.cc
@@ -151,7 +151,7 @@ class DriveSyncClientTest : public testing::Test {
// Notify the sync client that the network is changed. This is done via
// NetworkChangeNotifier in production, but here, we simulate the behavior
// by directly calling OnConnectionTypeChanged().
- sync_client_->OnConnectionTypeChanged(type);
+ sync_client_->OnNetworkChanged(type);
}
// Sets up MockNetworkChangeNotifier as if it's connected to wifi network.
@@ -384,7 +384,7 @@ TEST_F(DriveSyncClientTest, StartSyncLoop) {
SetExpectationForGetFileByResourceId("resource_id_not_fetched_baz");
SetExpectationForUpdateFileByResourceId("resource_id_dirty");
- sync_client_->StartSyncLoop();
+ sync_client_->StartSyncLoop(false);
}
TEST_F(DriveSyncClientTest, StartSyncLoop_Offline) {
@@ -398,7 +398,7 @@ TEST_F(DriveSyncClientTest, StartSyncLoop_Offline) {
// These files will be neither fetched nor uploaded not by DriveFileSystem,
// as network is not connected.
- sync_client_->StartSyncLoop();
+ sync_client_->StartSyncLoop(false);
}
TEST_F(DriveSyncClientTest, StartSyncLoop_ResumedConnection) {
@@ -412,7 +412,7 @@ TEST_F(DriveSyncClientTest, StartSyncLoop_ResumedConnection) {
// Disconnect from network on fetch try.
SetDisconnectingExpectationForGetFileByResourceId(resource_id);
- sync_client_->StartSyncLoop();
+ sync_client_->StartSyncLoop(false);
// Expect fetch retry on network reconnection.
EXPECT_CALL(*mock_file_system_, GetFileByResourceId(resource_id, _, _))
@@ -510,7 +510,7 @@ TEST_F(DriveSyncClientTest, StartSyncLoop_DriveDisabled) {
// These files will be neither fetched nor uploaded not by DriveFileSystem,
// as the Drive feature is disabled.
- sync_client_->StartSyncLoop();
+ sync_client_->StartSyncLoop(false);
}
TEST_F(DriveSyncClientTest, OnCachePinned) {
@@ -682,7 +682,7 @@ TEST_F(DriveSyncClientTest, ObserveDisconnection) {
AddResourceIdToFetch("resource_id_buz");
SetDisconnectingExpectationForGetFileByResourceId("resource_id_bar");
- sync_client_->StartSyncLoop();
+ sync_client_->StartSyncLoop(false);
EXPECT_EQ(TestObserver::STOPPED, observer_.state());
// So as the resume from the disconnection.

Powered by Google App Engine
This is Rietveld 408576698