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

Side by Side Diff: components/sync_driver/non_blocking_data_type_controller_unittest.cc

Issue 684513002: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 1 month 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 <list> 5 #include <list>
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
121 class NonBlockingDataTypeControllerTest : public testing::Test { 121 class NonBlockingDataTypeControllerTest : public testing::Test {
122 public: 122 public:
123 NonBlockingDataTypeControllerTest() 123 NonBlockingDataTypeControllerTest()
124 : type_sync_proxy_(syncer::DICTIONARY), 124 : type_sync_proxy_(syncer::DICTIONARY),
125 model_thread_(new base::TestSimpleTaskRunner()), 125 model_thread_(new base::TestSimpleTaskRunner()),
126 sync_thread_(new base::TestSimpleTaskRunner()), 126 sync_thread_(new base::TestSimpleTaskRunner()),
127 controller_(syncer::DICTIONARY, true), 127 controller_(syncer::DICTIONARY, true),
128 mock_context_proxy_(&mock_sync_context_, model_thread_, sync_thread_), 128 mock_context_proxy_(&mock_sync_context_, model_thread_, sync_thread_),
129 auto_run_tasks_(true) {} 129 auto_run_tasks_(true) {}
130 130
131 virtual ~NonBlockingDataTypeControllerTest() {} 131 ~NonBlockingDataTypeControllerTest() override {}
132 132
133 // Connects the sync type proxy to the NonBlockingDataTypeController. 133 // Connects the sync type proxy to the NonBlockingDataTypeController.
134 void InitTypeSyncProxy() { 134 void InitTypeSyncProxy() {
135 controller_.InitializeType(model_thread_, 135 controller_.InitializeType(model_thread_,
136 type_sync_proxy_.AsWeakPtrForUI()); 136 type_sync_proxy_.AsWeakPtrForUI());
137 if (auto_run_tasks_) { 137 if (auto_run_tasks_) {
138 RunAllTasks(); 138 RunAllTasks();
139 } 139 }
140 } 140 }
141 141
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 // disables sittin in its queue. Let's allow it to process them. 431 // disables sittin in its queue. Let's allow it to process them.
432 RunQueuedSyncThreadTasks(); 432 RunQueuedSyncThreadTasks();
433 433
434 // Let the model thread process any messages from the sync thread. 434 // Let the model thread process any messages from the sync thread.
435 RunQueuedModelThreadTasks(); 435 RunQueuedModelThreadTasks();
436 EXPECT_TRUE(type_sync_proxy_.IsPreferred()); 436 EXPECT_TRUE(type_sync_proxy_.IsPreferred());
437 EXPECT_TRUE(type_sync_proxy_.IsConnected()); 437 EXPECT_TRUE(type_sync_proxy_.IsConnected());
438 } 438 }
439 439
440 } // namespace sync_driver 440 } // namespace sync_driver
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698