OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/sync_file_system/drive_file_sync_service.h" | 5 #include "chrome/browser/sync_file_system/drive_file_sync_service.h" |
6 | 6 |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "base/message_loop_proxy.h" | 8 #include "base/message_loop_proxy.h" |
9 #include "chrome/browser/google_apis/gdata_errorcode.h" | 9 #include "chrome/browser/google_apis/gdata_errorcode.h" |
10 #include "chrome/browser/google_apis/mock_drive_service.h" | 10 #include "chrome/browser/google_apis/mock_drive_service.h" |
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
132 return DriveFileSyncClient::FormatTitleQuery(title); | 132 return DriveFileSyncClient::FormatTitleQuery(title); |
133 } | 133 } |
134 | 134 |
135 const DriveFileSyncService::ChangeQueue& pending_changes() const { | 135 const DriveFileSyncService::ChangeQueue& pending_changes() const { |
136 return sync_service_->pending_changes_; | 136 return sync_service_->pending_changes_; |
137 } | 137 } |
138 | 138 |
139 private: | 139 private: |
140 MessageLoop message_loop_; | 140 MessageLoop message_loop_; |
141 | 141 |
142 ScopedTempDir base_dir_; | 142 base::ScopedTempDir base_dir_; |
143 TestingProfile profile_; | 143 TestingProfile profile_; |
144 | 144 |
145 scoped_ptr<DriveFileSyncService> sync_service_; | 145 scoped_ptr<DriveFileSyncService> sync_service_; |
146 | 146 |
147 // Owned by |sync_client_|. | 147 // Owned by |sync_client_|. |
148 StrictMock<google_apis::MockDriveService>* mock_drive_service_; | 148 StrictMock<google_apis::MockDriveService>* mock_drive_service_; |
149 StrictMock<google_apis::MockDriveUploader>* mock_drive_uploader_; | 149 StrictMock<google_apis::MockDriveUploader>* mock_drive_uploader_; |
150 | 150 |
151 scoped_ptr<DriveFileSyncClient> sync_client_; | 151 scoped_ptr<DriveFileSyncClient> sync_client_; |
152 scoped_ptr<DriveMetadataStore> metadata_store_; | 152 scoped_ptr<DriveMetadataStore> metadata_store_; |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 EXPECT_TRUE(done); | 424 EXPECT_TRUE(done); |
425 | 425 |
426 EXPECT_TRUE(metadata_store()->batch_sync_origins().empty()); | 426 EXPECT_TRUE(metadata_store()->batch_sync_origins().empty()); |
427 EXPECT_EQ(1u, metadata_store()->incremental_sync_origins().size()); | 427 EXPECT_EQ(1u, metadata_store()->incremental_sync_origins().size()); |
428 EXPECT_TRUE(pending_changes().empty()); | 428 EXPECT_TRUE(pending_changes().empty()); |
429 } | 429 } |
430 | 430 |
431 #endif // !defined(OS_ANDROID) | 431 #endif // !defined(OS_ANDROID) |
432 | 432 |
433 } // namespace sync_file_system | 433 } // namespace sync_file_system |
OLD | NEW |