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

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

Issue 2539623002: [Extensions] Move [Chrome]ExtensionTestNotificationObserver into extensions:: (Closed)
Patch Set: Created 4 years 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 "chrome/browser/extensions/extension_browsertest.h" 5 #include "chrome/browser/extensions/extension_browsertest.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // running on chromeos. 140 // running on chromeos.
141 command_line->AppendSwitchASCII(chromeos::switches::kLoginUser, 141 command_line->AppendSwitchASCII(chromeos::switches::kLoginUser,
142 "testuser@gmail.com"); 142 "testuser@gmail.com");
143 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user"); 143 command_line->AppendSwitchASCII(chromeos::switches::kLoginProfile, "user");
144 } 144 }
145 #endif 145 #endif
146 } 146 }
147 147
148 void ExtensionBrowserTest::SetUpOnMainThread() { 148 void ExtensionBrowserTest::SetUpOnMainThread() {
149 InProcessBrowserTest::SetUpOnMainThread(); 149 InProcessBrowserTest::SetUpOnMainThread();
150 observer_.reset(new ChromeExtensionTestNotificationObserver(browser())); 150 observer_.reset(
151 new extensions::ChromeExtensionTestNotificationObserver(browser()));
151 if (extension_service()->updater()) { 152 if (extension_service()->updater()) {
152 extension_service()->updater()->SetExtensionCacheForTesting( 153 extension_service()->updater()->SetExtensionCacheForTesting(
153 test_extension_cache_.get()); 154 test_extension_cache_.get());
154 } 155 }
155 } 156 }
156 157
157 void ExtensionBrowserTest::TearDownOnMainThread() { 158 void ExtensionBrowserTest::TearDownOnMainThread() {
158 ExtensionMessageBubbleFactory::set_override_for_tests( 159 ExtensionMessageBubbleFactory::set_override_for_tests(
159 ExtensionMessageBubbleFactory::NO_OVERRIDE); 160 ExtensionMessageBubbleFactory::NO_OVERRIDE);
160 InProcessBrowserTest::TearDownOnMainThread(); 161 InProcessBrowserTest::TearDownOnMainThread();
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
550 return extensions::browsertest_util::ExecuteScriptInBackgroundPage( 551 return extensions::browsertest_util::ExecuteScriptInBackgroundPage(
551 profile(), extension_id, script); 552 profile(), extension_id, script);
552 } 553 }
553 554
554 bool ExtensionBrowserTest::ExecuteScriptInBackgroundPageNoWait( 555 bool ExtensionBrowserTest::ExecuteScriptInBackgroundPageNoWait(
555 const std::string& extension_id, 556 const std::string& extension_id,
556 const std::string& script) { 557 const std::string& script) {
557 return extensions::browsertest_util::ExecuteScriptInBackgroundPageNoWait( 558 return extensions::browsertest_util::ExecuteScriptInBackgroundPageNoWait(
558 profile(), extension_id, script); 559 profile(), extension_id, script);
559 } 560 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_browsertest.h ('k') | chrome/browser/ui/webui/extensions/extension_settings_browsertest.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698