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

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

Issue 1203713002: Limit access to ChromeBookmarkClient to bookmarks code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup_bookmark_client
Patch Set: Rebase Created 5 years, 6 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..7572481e7c8c2c2c1728b60fbe2695ddbcb4c8a2 100644
--- a/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
+++ b/chrome/browser/ui/views/bookmarks/bookmark_context_menu_unittest.cc
@@ -15,8 +15,6 @@
#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/profiles/profile.h"
#include "chrome/browser/ui/bookmarks/bookmark_utils.h"
#include "chrome/common/pref_names.h"
@@ -349,9 +347,7 @@ 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());
+ EXPECT_TRUE(model_->managed_node()->empty());
// The context menu should not show the option to "Show managed bookmarks".
EXPECT_FALSE(
@@ -370,9 +366,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(model_->managed_node()->empty());
profile_->GetPrefs()->Set(bookmarks::prefs::kManagedBookmarks, list);
- EXPECT_FALSE(client->managed_node()->empty());
+ EXPECT_FALSE(model_->managed_node()->empty());
// New context menus now show the "Show managed bookmarks" option.
controller.reset(new BookmarkContextMenu(

Powered by Google App Engine
This is Rietveld 408576698