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

Side by Side Diff: chrome/browser/extensions/api/extension_action/browser_action_apitest.cc

Issue 67253003: Reland: Move ExtensionProcessManager to src/extensions, part 4 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase process_manager Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "build/build_config.h" 5 #include "build/build_config.h"
6 6
7 #if defined(TOOLKIT_GTK) 7 #if defined(TOOLKIT_GTK)
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 #endif 9 #endif
10 10
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after
605 } 605 }
606 606
607 // Disabled because of failures (crashes) on ASAN bot. 607 // Disabled because of failures (crashes) on ASAN bot.
608 // See http://crbug.com/98861. 608 // See http://crbug.com/98861.
609 IN_PROC_BROWSER_TEST_F(BrowserActionApiTest, DISABLED_CloseBackgroundPage) { 609 IN_PROC_BROWSER_TEST_F(BrowserActionApiTest, DISABLED_CloseBackgroundPage) {
610 ASSERT_TRUE(LoadExtension(test_data_dir_.AppendASCII( 610 ASSERT_TRUE(LoadExtension(test_data_dir_.AppendASCII(
611 "browser_action/close_background"))); 611 "browser_action/close_background")));
612 const Extension* extension = GetSingleLoadedExtension(); 612 const Extension* extension = GetSingleLoadedExtension();
613 613
614 // There is a background page and a browser action with no badge text. 614 // There is a background page and a browser action with no badge text.
615 ExtensionProcessManager* manager = 615 extensions::ProcessManager* manager =
616 extensions::ExtensionSystem::Get(browser()->profile())->process_manager(); 616 extensions::ExtensionSystem::Get(browser()->profile())->process_manager();
617 ASSERT_TRUE(manager->GetBackgroundHostForExtension(extension->id())); 617 ASSERT_TRUE(manager->GetBackgroundHostForExtension(extension->id()));
618 ExtensionAction* action = GetBrowserAction(*extension); 618 ExtensionAction* action = GetBrowserAction(*extension);
619 ASSERT_EQ("", action->GetBadgeText(ExtensionAction::kDefaultTabId)); 619 ASSERT_EQ("", action->GetBadgeText(ExtensionAction::kDefaultTabId));
620 620
621 content::WindowedNotificationObserver host_destroyed_observer( 621 content::WindowedNotificationObserver host_destroyed_observer(
622 chrome::NOTIFICATION_EXTENSION_HOST_DESTROYED, 622 chrome::NOTIFICATION_EXTENSION_HOST_DESTROYED,
623 content::NotificationService::AllSources()); 623 content::NotificationService::AllSources());
624 624
625 // Click the browser action. 625 // Click the browser action.
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
723 "backgroundColor);"; 723 "backgroundColor);";
724 std::string result; 724 std::string result;
725 const std::string frame_xpath; 725 const std::string frame_xpath;
726 EXPECT_TRUE(content::ExecuteScriptInFrameAndExtractString( 726 EXPECT_TRUE(content::ExecuteScriptInFrameAndExtractString(
727 tab, frame_xpath, script, &result)); 727 tab, frame_xpath, script, &result));
728 EXPECT_EQ(result, "red"); 728 EXPECT_EQ(result, "red");
729 } 729 }
730 730
731 } // namespace 731 } // namespace
732 } // namespace extensions 732 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698