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

Side by Side Diff: chrome/browser/chromeos/drive/sync_client_unittest.cc

Issue 623293003: replace OVERRIDE and FINAL with override and final in chrome/browser/chromeos/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: run git cl format on echo_dialog_view.h Created 6 years, 2 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 unified diff | Download patch
OLDNEW
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/chromeos/drive/sync_client.h" 5 #include "chrome/browser/chromeos/drive/sync_client.h"
6 6
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "base/files/scoped_temp_dir.h" 9 #include "base/files/scoped_temp_dir.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 class SyncClientTestDriveService : public ::drive::FakeDriveService { 47 class SyncClientTestDriveService : public ::drive::FakeDriveService {
48 public: 48 public:
49 SyncClientTestDriveService() : download_file_count_(0) {} 49 SyncClientTestDriveService() : download_file_count_(0) {}
50 50
51 // FakeDriveService override: 51 // FakeDriveService override:
52 virtual google_apis::CancelCallback DownloadFile( 52 virtual google_apis::CancelCallback DownloadFile(
53 const base::FilePath& local_cache_path, 53 const base::FilePath& local_cache_path,
54 const std::string& resource_id, 54 const std::string& resource_id,
55 const google_apis::DownloadActionCallback& download_action_callback, 55 const google_apis::DownloadActionCallback& download_action_callback,
56 const google_apis::GetContentCallback& get_content_callback, 56 const google_apis::GetContentCallback& get_content_callback,
57 const google_apis::ProgressCallback& progress_callback) OVERRIDE { 57 const google_apis::ProgressCallback& progress_callback) override {
58 ++download_file_count_; 58 ++download_file_count_;
59 if (resource_id == resource_id_to_be_cancelled_) { 59 if (resource_id == resource_id_to_be_cancelled_) {
60 base::MessageLoopProxy::current()->PostTask( 60 base::MessageLoopProxy::current()->PostTask(
61 FROM_HERE, 61 FROM_HERE,
62 base::Bind(download_action_callback, 62 base::Bind(download_action_callback,
63 google_apis::GDATA_CANCELLED, 63 google_apis::GDATA_CANCELLED,
64 base::FilePath())); 64 base::FilePath()));
65 return google_apis::CancelCallback(); 65 return google_apis::CancelCallback();
66 } 66 }
67 if (resource_id == resource_id_to_be_paused_) { 67 if (resource_id == resource_id_to_be_paused_) {
(...skipping 25 matching lines...) Expand all
93 int download_file_count_; 93 int download_file_count_;
94 std::string resource_id_to_be_cancelled_; 94 std::string resource_id_to_be_cancelled_;
95 std::string resource_id_to_be_paused_; 95 std::string resource_id_to_be_paused_;
96 base::Closure paused_action_; 96 base::Closure paused_action_;
97 }; 97 };
98 98
99 } // namespace 99 } // namespace
100 100
101 class SyncClientTest : public testing::Test { 101 class SyncClientTest : public testing::Test {
102 public: 102 public:
103 virtual void SetUp() OVERRIDE { 103 virtual void SetUp() override {
104 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); 104 ASSERT_TRUE(temp_dir_.CreateUniqueTempDir());
105 105
106 pref_service_.reset(new TestingPrefServiceSimple); 106 pref_service_.reset(new TestingPrefServiceSimple);
107 test_util::RegisterDrivePrefs(pref_service_->registry()); 107 test_util::RegisterDrivePrefs(pref_service_->registry());
108 108
109 fake_network_change_notifier_.reset( 109 fake_network_change_notifier_.reset(
110 new test_util::FakeNetworkChangeNotifier); 110 new test_util::FakeNetworkChangeNotifier);
111 111
112 logger_.reset(new EventLogger); 112 logger_.reset(new EventLogger);
113 113
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
511 local_id, google_apis::test_util::CreateCopyResultCallback(&error))); 511 local_id, google_apis::test_util::CreateCopyResultCallback(&error)));
512 512
513 base::RunLoop().RunUntilIdle(); 513 base::RunLoop().RunUntilIdle();
514 514
515 // The callback is called. 515 // The callback is called.
516 EXPECT_EQ(FILE_ERROR_OK, error); 516 EXPECT_EQ(FILE_ERROR_OK, error);
517 } 517 }
518 518
519 } // namespace internal 519 } // namespace internal
520 } // namespace drive 520 } // namespace drive
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/drive/sync/entry_update_performer_unittest.cc ('k') | chrome/browser/chromeos/drive/test_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698