| 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 #include "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/message_loop.h" | 6 #include "base/message_loop.h" |
| 7 #include "base/string16.h" | 7 #include "base/string16.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "chrome/app/chrome_command_ids.h" | 9 #include "chrome/app/chrome_command_ids.h" |
| 10 #include "chrome/browser/bookmarks/bookmark_model.h" | 10 #include "chrome/browser/bookmarks/bookmark_model.h" |
| 11 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 11 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
| 12 #include "chrome/browser/bookmarks/bookmark_utils.h" | 12 #include "chrome/browser/bookmarks/bookmark_utils.h" |
| 13 #include "chrome/browser/ui/browser.h" | 13 #include "chrome/browser/ui/browser.h" |
| 14 #include "chrome/browser/ui/browser_commands.h" | 14 #include "chrome/browser/ui/browser_commands.h" |
| 15 #include "chrome/browser/ui/browser_tabstrip.h" | 15 #include "chrome/browser/ui/browser_tabstrip.h" |
| 16 #include "chrome/browser/ui/browser_window.h" | 16 #include "chrome/browser/ui/browser_window.h" |
| 17 #include "chrome/browser/ui/omnibox/location_bar.h" | 17 #include "chrome/browser/ui/omnibox/location_bar.h" |
| 18 #include "chrome/browser/ui/toolbar/action_box_menu_model.h" | 18 #include "chrome/browser/ui/toolbar/action_box_menu_model.h" |
| 19 #include "chrome/common/chrome_notification_types.h" | 19 #include "chrome/common/chrome_notification_types.h" |
| 20 #include "chrome/common/chrome_paths.h" | 20 #include "chrome/common/chrome_paths.h" |
| 21 #include "chrome/common/chrome_switches.h" | 21 #include "chrome/common/chrome_switches.h" |
| 22 #include "chrome/common/url_constants.h" | 22 #include "chrome/common/url_constants.h" |
| 23 #include "chrome/test/base/interactive_test_utils.h" |
| 23 #include "chrome/test/base/in_process_browser_test.h" | 24 #include "chrome/test/base/in_process_browser_test.h" |
| 24 #include "chrome/test/base/testing_profile.h" | 25 #include "chrome/test/base/testing_profile.h" |
| 25 #include "chrome/test/base/ui_test_utils.h" | 26 #include "chrome/test/base/ui_test_utils.h" |
| 26 #include "content/public/browser/notification_service.h" | 27 #include "content/public/browser/notification_service.h" |
| 27 #include "content/public/browser/web_contents.h" | 28 #include "content/public/browser/web_contents.h" |
| 28 | 29 |
| 29 class ActionBoxTest : public InProcessBrowserTest, | 30 class ActionBoxTest : public InProcessBrowserTest, |
| 30 public content::NotificationObserver { | 31 public content::NotificationObserver { |
| 31 protected: | 32 protected: |
| 32 ActionBoxTest() {} | 33 ActionBoxTest() {} |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 93 // Get the BookmarkModel to unbookmark the bookmark. | 94 // Get the BookmarkModel to unbookmark the bookmark. |
| 94 BookmarkModel* model = | 95 BookmarkModel* model = |
| 95 BookmarkModelFactory::GetForProfile(browser()->profile()); | 96 BookmarkModelFactory::GetForProfile(browser()->profile()); |
| 96 ui_test_utils::WaitForBookmarkModelToLoad(model); | 97 ui_test_utils::WaitForBookmarkModelToLoad(model); |
| 97 bookmark_utils::RemoveAllBookmarks(model, GURL("http://www.google.com")); | 98 bookmark_utils::RemoveAllBookmarks(model, GURL("http://www.google.com")); |
| 98 | 99 |
| 99 // Page is now unbookmarked. | 100 // Page is now unbookmarked. |
| 100 ASSERT_FALSE(loc_bar->GetBookmarkStarVisibility()); | 101 ASSERT_FALSE(loc_bar->GetBookmarkStarVisibility()); |
| 101 | 102 |
| 102 } | 103 } |
| OLD | NEW |