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

Unified Diff: chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc

Issue 1233673002: Fix componentization of chrome/browser/bookmarks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix "gn check" and compilation on Mac Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
diff --git a/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc b/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
index a65489f00a3aec2abaf87ca5ef40b90a00459648..1608880a6dc29f690036216beadaea55665905c2 100644
--- a/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
+++ b/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
@@ -15,13 +15,13 @@
#include "base/values.h"
#include "chrome/app/chrome_command_ids.h"
#include "chrome/browser/bookmarks/bookmark_model_factory.h"
-#include "chrome/browser/bookmarks/chrome_bookmark_client.h"
-#include "chrome/browser/bookmarks/chrome_bookmark_client_factory.h"
+#include "chrome/browser/bookmarks/managed_bookmark_service_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/bookmarks/bookmark_utils.h"
#include "chrome/common/pref_names.h"
#include "chrome/test/base/testing_profile.h"
#include "components/bookmarks/browser/bookmark_model.h"
+#include "components/bookmarks/managed/managed_bookmark_service.h"
#include "components/bookmarks/test/bookmark_test_helpers.h"
#include "content/public/browser/page_navigator.h"
#include "content/public/test/test_browser_thread.h"
@@ -349,9 +349,9 @@ TEST_F(BookmarkContextMenuTest, ShowManagedBookmarks) {
NULL, NULL, profile_.get(), NULL, nodes[0]->parent(), nodes, false));
// Verify that there are no managed nodes yet.
- ChromeBookmarkClient* client = ChromeBookmarkClientFactory::GetForProfile(
- profile_.get());
- EXPECT_TRUE(client->managed_node()->empty());
+ bookmarks::ManagedBookmarkService* managed =
+ ManagedBookmarkServiceFactory::GetForProfile(profile_.get());
+ EXPECT_TRUE(managed->managed_node()->empty());
// The context menu should not show the option to "Show managed bookmarks".
EXPECT_FALSE(
@@ -370,9 +370,9 @@ TEST_F(BookmarkContextMenuTest, ShowManagedBookmarks) {
dict->SetString("url", "http://google.com");
base::ListValue list;
list.Append(dict);
- EXPECT_TRUE(client->managed_node()->empty());
+ EXPECT_TRUE(managed->managed_node()->empty());
profile_->GetPrefs()->Set(bookmarks::prefs::kManagedBookmarks, list);
- EXPECT_FALSE(client->managed_node()->empty());
+ EXPECT_FALSE(managed->managed_node()->empty());
// New context menus now show the "Show managed bookmarks" option.
controller.reset(new BookmarkContextMenu(
« no previous file with comments | « chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc ('k') | chrome/browser/ui/views/bookmarks/bookmark_menu_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698