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

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

Issue 2825963003: Rewrite base::Bind to base::BindOnce with base_bind_rewriters in //chrome/browser/extensions (Closed)
Patch Set: Created 3 years, 8 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 // Contains holistic tests of the bindings infrastructure 5 // Contains holistic tests of the bindings infrastructure
6 6
7 #include "chrome/browser/extensions/api/permissions/permissions_api.h" 7 #include "chrome/browser/extensions/api/permissions/permissions_api.h"
8 #include "chrome/browser/extensions/extension_apitest.h" 8 #include "chrome/browser/extensions/extension_apitest.h"
9 #include "chrome/browser/net/url_request_mock_util.h" 9 #include "chrome/browser/net/url_request_mock_util.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
(...skipping 10 matching lines...) Expand all
21 21
22 namespace extensions { 22 namespace extensions {
23 namespace { 23 namespace {
24 24
25 class ExtensionBindingsApiTest : public ExtensionApiTest { 25 class ExtensionBindingsApiTest : public ExtensionApiTest {
26 public: 26 public:
27 void SetUpOnMainThread() override { 27 void SetUpOnMainThread() override {
28 ExtensionApiTest::SetUpOnMainThread(); 28 ExtensionApiTest::SetUpOnMainThread();
29 content::BrowserThread::PostTask( 29 content::BrowserThread::PostTask(
30 content::BrowserThread::IO, FROM_HERE, 30 content::BrowserThread::IO, FROM_HERE,
31 base::Bind(&chrome_browser_net::SetUrlRequestMocksEnabled, true)); 31 base::BindOnce(&chrome_browser_net::SetUrlRequestMocksEnabled, true));
32 } 32 }
33 }; 33 };
34 34
35 IN_PROC_BROWSER_TEST_F(ExtensionBindingsApiTest, 35 IN_PROC_BROWSER_TEST_F(ExtensionBindingsApiTest,
36 UnavailableBindingsNeverRegistered) { 36 UnavailableBindingsNeverRegistered) {
37 // Test will request the 'storage' permission. 37 // Test will request the 'storage' permission.
38 PermissionsRequestFunction::SetIgnoreUserGestureForTests(true); 38 PermissionsRequestFunction::SetIgnoreUserGestureForTests(true);
39 ASSERT_TRUE(RunExtensionTest( 39 ASSERT_TRUE(RunExtensionTest(
40 "bindings/unavailable_bindings_never_registered")) << message_; 40 "bindings/unavailable_bindings_never_registered")) << message_;
41 } 41 }
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 ASSERT_TRUE(content::ExecuteScriptAndExtractInt( 265 ASSERT_TRUE(content::ExecuteScriptAndExtractInt(
266 ProcessManager::Get(profile()) 266 ProcessManager::Get(profile())
267 ->GetBackgroundHostForExtension(receiver->id()) 267 ->GetBackgroundHostForExtension(receiver->id())
268 ->host_contents(), 268 ->host_contents(),
269 "getMessageCountAfterReceivingRealSenderMessage()", &message_count)); 269 "getMessageCountAfterReceivingRealSenderMessage()", &message_count));
270 EXPECT_EQ(1, message_count); 270 EXPECT_EQ(1, message_count);
271 } 271 }
272 272
273 } // namespace 273 } // namespace
274 } // namespace extensions 274 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_action_runner.cc ('k') | chrome/browser/extensions/extension_cookie_monster_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698