OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // TODO(akalin): This file is basically just a unit test for | 5 // TODO(akalin): This file is basically just a unit test for |
6 // BookmarkChangeProcessor. Write unit tests for | 6 // BookmarkChangeProcessor. Write unit tests for |
7 // BookmarkModelAssociator separately. | 7 // BookmarkModelAssociator separately. |
8 | 8 |
9 #include <stack> | 9 #include <stack> |
10 #include <vector> | 10 #include <vector> |
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
289 model_(NULL) { | 289 model_(NULL) { |
290 } | 290 } |
291 | 291 |
292 virtual ~ProfileSyncServiceBookmarkTest() { | 292 virtual ~ProfileSyncServiceBookmarkTest() { |
293 StopSync(); | 293 StopSync(); |
294 UnloadBookmarkModel(); | 294 UnloadBookmarkModel(); |
295 } | 295 } |
296 | 296 |
297 virtual void SetUp() { | 297 virtual void SetUp() { |
298 test_user_share_.SetUp(); | 298 test_user_share_.SetUp(); |
299 CommandLine::ForCurrentProcess()->AppendSwitch( | |
300 switches::kCreateMobileBookmarksFolder); | |
301 } | 299 } |
302 | 300 |
303 virtual void TearDown() { | 301 virtual void TearDown() { |
304 test_user_share_.TearDown(); | 302 test_user_share_.TearDown(); |
305 } | 303 } |
306 | 304 |
307 // Load (or re-load) the bookmark model. |load| controls use of the | 305 // Load (or re-load) the bookmark model. |load| controls use of the |
308 // bookmarks file on disk. |save| controls whether the newly loaded | 306 // bookmarks file on disk. |save| controls whether the newly loaded |
309 // bookmark model will write out a bookmark file as it goes. | 307 // bookmark model will write out a bookmark file as it goes. |
310 void LoadBookmarkModel(LoadOption load, SaveOption save) { | 308 void LoadBookmarkModel(LoadOption load, SaveOption save) { |
(...skipping 1118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1429 // Make sure we're back in sync. In real life, the user would need | 1427 // Make sure we're back in sync. In real life, the user would need |
1430 // to reauthenticate before this happens, but in the test, authentication | 1428 // to reauthenticate before this happens, but in the test, authentication |
1431 // is sidestepped. | 1429 // is sidestepped. |
1432 ExpectBookmarkModelMatchesTestData(); | 1430 ExpectBookmarkModelMatchesTestData(); |
1433 ExpectModelMatch(); | 1431 ExpectModelMatch(); |
1434 } | 1432 } |
1435 | 1433 |
1436 } // namespace | 1434 } // namespace |
1437 | 1435 |
1438 } // namespace browser_sync | 1436 } // namespace browser_sync |
OLD | NEW |