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

Side by Side Diff: components/sync/driver/startup_controller_unittest.cc

Issue 2395533003: [Sync] Move some things from driver to base. (Closed)
Patch Set: Rebase. Created 4 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 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 "components/sync/driver/startup_controller.h" 5 #include "components/sync/driver/startup_controller.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
11 #include "base/run_loop.h" 11 #include "base/run_loop.h"
12 #include "components/sync/base/sync_prefs.h"
12 #include "components/sync/driver/sync_driver_switches.h" 13 #include "components/sync/driver/sync_driver_switches.h"
13 #include "components/sync/driver/sync_prefs.h"
14 #include "components/syncable_prefs/testing_pref_service_syncable.h" 14 #include "components/syncable_prefs/testing_pref_service_syncable.h"
15 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
16 16
17 namespace syncer { 17 namespace syncer {
18 18
19 // These are coupled to the implementation of StartupController's 19 // These are coupled to the implementation of StartupController's
20 // GetBackendInitializationStateString which is used by about:sync. We use it 20 // GetBackendInitializationStateString which is used by about:sync. We use it
21 // as a convenient way to verify internal state and that the class is 21 // as a convenient way to verify internal state and that the class is
22 // outputting the correct values for the debug string. 22 // outputting the correct values for the debug string.
23 static const char kStateStringStarted[] = "Started"; 23 static const char kStateStringStarted[] = "Started";
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 controller()->SetSetupInProgress(true); 203 controller()->SetSetupInProgress(true);
204 204
205 // This could happen if the UI triggers a stop-syncing permanently call. 205 // This could happen if the UI triggers a stop-syncing permanently call.
206 controller()->Reset(UserTypes()); 206 controller()->Reset(UserTypes());
207 207
208 // From the UI's point of view, setup is still in progress. 208 // From the UI's point of view, setup is still in progress.
209 EXPECT_TRUE(controller()->IsSetupInProgress()); 209 EXPECT_TRUE(controller()->IsSetupInProgress());
210 } 210 }
211 211
212 } // namespace syncer 212 } // namespace syncer
OLDNEW
« no previous file with comments | « components/sync/driver/startup_controller.cc ('k') | components/sync/driver/sync_policy_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698