OLD | NEW |
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/bookmarks/managed/managed_bookmarks_tracker.h" | 5 #include "components/bookmarks/managed/managed_bookmarks_tracker.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/files/file_path.h" | 11 #include "base/files/file_path.h" |
12 #include "base/message_loop/message_loop.h" | 12 #include "base/message_loop/message_loop.h" |
13 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
14 #include "base/thread_task_runner_handle.h" | 14 #include "base/threading/thread_task_runner_handle.h" |
15 #include "components/bookmarks/browser/bookmark_model.h" | 15 #include "components/bookmarks/browser/bookmark_model.h" |
16 #include "components/bookmarks/browser/bookmark_model_observer.h" | 16 #include "components/bookmarks/browser/bookmark_model_observer.h" |
17 #include "components/bookmarks/browser/bookmark_node.h" | 17 #include "components/bookmarks/browser/bookmark_node.h" |
18 #include "components/bookmarks/browser/bookmark_utils.h" | 18 #include "components/bookmarks/browser/bookmark_utils.h" |
19 #include "components/bookmarks/common/bookmark_pref_names.h" | 19 #include "components/bookmarks/common/bookmark_pref_names.h" |
20 #include "components/bookmarks/test/bookmark_test_helpers.h" | 20 #include "components/bookmarks/test/bookmark_test_helpers.h" |
21 #include "components/bookmarks/test/mock_bookmark_model_observer.h" | 21 #include "components/bookmarks/test/mock_bookmark_model_observer.h" |
22 #include "components/bookmarks/test/test_bookmark_client.h" | 22 #include "components/bookmarks/test/test_bookmark_client.h" |
23 #include "components/prefs/pref_registry_simple.h" | 23 #include "components/prefs/pref_registry_simple.h" |
24 #include "components/prefs/testing_pref_service.h" | 24 #include "components/prefs/testing_pref_service.h" |
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 Mock::VerifyAndClearExpectations(&observer_); | 351 Mock::VerifyAndClearExpectations(&observer_); |
352 | 352 |
353 EXPECT_CALL(observer_, BookmarkAllUserNodesRemoved(model_.get(), _)); | 353 EXPECT_CALL(observer_, BookmarkAllUserNodesRemoved(model_.get(), _)); |
354 model_->RemoveAllUserBookmarks(); | 354 model_->RemoveAllUserBookmarks(); |
355 EXPECT_EQ(2, managed_node()->child_count()); | 355 EXPECT_EQ(2, managed_node()->child_count()); |
356 EXPECT_EQ(0, model_->bookmark_bar_node()->child_count()); | 356 EXPECT_EQ(0, model_->bookmark_bar_node()->child_count()); |
357 Mock::VerifyAndClearExpectations(&observer_); | 357 Mock::VerifyAndClearExpectations(&observer_); |
358 } | 358 } |
359 | 359 |
360 } // namespace bookmarks | 360 } // namespace bookmarks |
OLD | NEW |