| 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 // 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 <map> | 9 #include <map> |
| 10 #include <queue> | 10 #include <queue> |
| (...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 359 | 359 |
| 360 virtual void SetUp() { | 360 virtual void SetUp() { |
| 361 test_user_share_.SetUp(); | 361 test_user_share_.SetUp(); |
| 362 } | 362 } |
| 363 | 363 |
| 364 virtual void TearDown() { | 364 virtual void TearDown() { |
| 365 test_user_share_.TearDown(); | 365 test_user_share_.TearDown(); |
| 366 } | 366 } |
| 367 | 367 |
| 368 bool CanSyncNode(const BookmarkNode* node) { | 368 bool CanSyncNode(const BookmarkNode* node) { |
| 369 return model_->client()->CanSyncNode(node); | 369 return model_->CanSyncNode(node); |
| 370 } | 370 } |
| 371 | 371 |
| 372 // Inserts a folder directly to the share. | 372 // Inserts a folder directly to the share. |
| 373 // Do not use this after model association is complete. | 373 // Do not use this after model association is complete. |
| 374 // | 374 // |
| 375 // This function differs from the AddFolder() function declared elsewhere in | 375 // This function differs from the AddFolder() function declared elsewhere in |
| 376 // this file in that it only affects the sync model. It would be invalid to | 376 // this file in that it only affects the sync model. It would be invalid to |
| 377 // change the sync model directly after ModelAssociation. This function can | 377 // change the sync model directly after ModelAssociation. This function can |
| 378 // be invoked prior to model association to set up first-time sync model | 378 // be invoked prior to model association to set up first-time sync model |
| 379 // association scenarios. | 379 // association scenarios. |
| (...skipping 2194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2574 ExpectModelMatch(); | 2574 ExpectModelMatch(); |
| 2575 | 2575 |
| 2576 // Then simulate the add call arriving late. | 2576 // Then simulate the add call arriving late. |
| 2577 change_processor_->BookmarkNodeAdded(model_, model_->bookmark_bar_node(), 0); | 2577 change_processor_->BookmarkNodeAdded(model_, model_->bookmark_bar_node(), 0); |
| 2578 ExpectModelMatch(); | 2578 ExpectModelMatch(); |
| 2579 } | 2579 } |
| 2580 | 2580 |
| 2581 } // namespace | 2581 } // namespace |
| 2582 | 2582 |
| 2583 } // namespace browser_sync | 2583 } // namespace browser_sync |
| OLD | NEW |