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

Side by Side Diff: chrome/browser/extensions/extension_devtools_browsertests.cc

Issue 10824030: Move ExtensionHost into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Latest master for cq Created 8 years, 4 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 unified diff | Download patch
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 "base/memory/ref_counted.h" 5 #include "base/memory/ref_counted.h"
6 #include "base/stringprintf.h" 6 #include "base/stringprintf.h"
7 #include "chrome/browser/extensions/extension_devtools_browsertest.h" 7 #include "chrome/browser/extensions/extension_devtools_browsertest.h"
8 #include "chrome/browser/extensions/extension_error_reporter.h" 8 #include "chrome/browser/extensions/extension_error_reporter.h"
9 #include "chrome/browser/extensions/extension_host.h" 9 #include "chrome/browser/extensions/extension_host.h"
10 #include "chrome/browser/extensions/extension_process_manager.h" 10 #include "chrome/browser/extensions/extension_process_manager.h"
(...skipping 13 matching lines...) Expand all
24 #include "content/public/browser/render_view_host.h" 24 #include "content/public/browser/render_view_host.h"
25 #include "content/public/browser/web_contents.h" 25 #include "content/public/browser/web_contents.h"
26 #include "content/public/test/browser_test_utils.h" 26 #include "content/public/test/browser_test_utils.h"
27 #include "net/base/net_util.h" 27 #include "net/base/net_util.h"
28 28
29 using content::DevToolsAgentHost; 29 using content::DevToolsAgentHost;
30 using content::DevToolsAgentHostRegistry; 30 using content::DevToolsAgentHostRegistry;
31 using content::DevToolsClientHost; 31 using content::DevToolsClientHost;
32 using content::DevToolsManager; 32 using content::DevToolsManager;
33 using content::WebContents; 33 using content::WebContents;
34 using extensions::ExtensionHost;
34 35
35 // Looks for an background ExtensionHost whose URL has the given path component 36 // Looks for an background ExtensionHost whose URL has the given path component
36 // (including leading slash). Also verifies that the expected number of hosts 37 // (including leading slash). Also verifies that the expected number of hosts
37 // are loaded. 38 // are loaded.
38 static ExtensionHost* FindBackgroundHostWithPath( 39 static ExtensionHost* FindBackgroundHostWithPath(
39 ExtensionProcessManager* manager, 40 ExtensionProcessManager* manager,
40 const std::string& path, 41 const std::string& path,
41 int expected_hosts) { 42 int expected_hosts) {
42 ExtensionHost* host = NULL; 43 ExtensionHost* host = NULL;
43 int num_hosts = 0; 44 int num_hosts = 0;
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 // Removing the listeners from the second extension should tear the bridge 169 // Removing the listeners from the second extension should tear the bridge
169 // down. 170 // down.
170 result = false; 171 result = false;
171 ASSERT_TRUE(content::ExecuteJavaScriptAndExtractBool( 172 ASSERT_TRUE(content::ExecuteJavaScriptAndExtractBool(
172 host_two->render_view_host(), L"", L"unregisterListeners()", &result)); 173 host_two->render_view_host(), L"", L"unregisterListeners()", &result));
173 EXPECT_TRUE(result); 174 EXPECT_TRUE(result);
174 ASSERT_FALSE(devtools_manager->GetDevToolsClientHostFor( 175 ASSERT_FALSE(devtools_manager->GetDevToolsClientHostFor(
175 DevToolsAgentHostRegistry::GetDevToolsAgentHost( 176 DevToolsAgentHostRegistry::GetDevToolsAgentHost(
176 web_contents->GetRenderViewHost()))); 177 web_contents->GetRenderViewHost())));
177 } 178 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_crash_recovery_browsertest.cc ('k') | chrome/browser/extensions/extension_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698