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

Unified Diff: extensions/shell/test/shell_test.cc

Issue 2182633007: Avoid using ContentBrowserClient::IsIllegalOrigin in ResourceDispatcherHost. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove the IsIllegalOrigin function from ContentBrowserClient Created 4 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 side-by-side diff with in-line comments
Download patch
Index: extensions/shell/test/shell_test.cc
diff --git a/extensions/shell/test/shell_test.cc b/extensions/shell/test/shell_test.cc
index 96ebb2a69441fd8adaee050cd2cafb93f0d97113..a4efedc170b17b2c141f7db3faf60bf4a0746a46 100644
--- a/extensions/shell/test/shell_test.cc
+++ b/extensions/shell/test/shell_test.cc
@@ -11,8 +11,10 @@
#include "base/path_service.h"
#include "build/build_config.h"
#include "components/version_info/version_info.h"
+#include "content/public/browser/resource_dispatcher_host.h"
#include "content/public/common/content_switches.h"
#include "extensions/browser/extension_system.h"
+#include "extensions/common/constants.h"
#include "extensions/shell/browser/desktop_controller.h"
#include "extensions/shell/browser/shell_content_browser_client.h"
#include "extensions/shell/browser/shell_extension_system.h"
@@ -54,6 +56,9 @@ void AppShellTest::SetUpOnMainThread() {
extension_system_ = static_cast<ShellExtensionSystem*>(
ExtensionSystem::Get(browser_context_));
+
+ content::ResourceDispatcherHost::Get()->AddSchemeForAccessCheck(
+ extensions::kExtensionScheme);
}
void AppShellTest::RunTestOnMainThreadLoop() {

Powered by Google App Engine
This is Rietveld 408576698