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

Side by Side Diff: content/browser/plugin_service_browsertest.cc

Issue 7661031: Tag IPC::Channel::Listener implementations with OVERRIDE (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « content/browser/plugin_process_host.h ('k') | content/browser/ppapi_broker_process_host.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "content/browser/plugin_service.h" 5 #include "content/browser/plugin_service.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "chrome/test/base/in_process_browser_test.h" 9 #include "chrome/test/base/in_process_browser_test.h"
10 #include "chrome/test/base/ui_test_utils.h" 10 #include "chrome/test/base/ui_test_utils.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 void SetPluginInfo(const webkit::WebPluginInfo& info) { 47 void SetPluginInfo(const webkit::WebPluginInfo& info) {
48 ASSERT_TRUE(info.mime_types.size()); 48 ASSERT_TRUE(info.mime_types.size());
49 ASSERT_EQ(kNPAPITestPluginMimeType, info.mime_types[0].mime_type); 49 ASSERT_EQ(kNPAPITestPluginMimeType, info.mime_types[0].mime_type);
50 set_plugin_info_called_ = true; 50 set_plugin_info_called_ = true;
51 } 51 }
52 52
53 MOCK_METHOD0(OnError, void()); 53 MOCK_METHOD0(OnError, void());
54 54
55 // Listener implementation. 55 // Listener implementation.
56 MOCK_METHOD1(OnMessageReceived, bool(const IPC::Message& message)); 56 MOCK_METHOD1(OnMessageReceived, bool(const IPC::Message& message));
57 void OnChannelConnected(int32 peer_pid) { 57 void OnChannelConnected(int32 peer_pid) OVERRIDE {
58 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, 58 BrowserThread::PostTask(BrowserThread::UI, FROM_HERE,
59 new MessageLoop::QuitTask()); 59 new MessageLoop::QuitTask());
60 } 60 }
61 MOCK_METHOD0(OnChannelError, void()); 61 MOCK_METHOD0(OnChannelError, void());
62 MOCK_METHOD0(OnChannelDenied, void()); 62 MOCK_METHOD0(OnChannelDenied, void());
63 MOCK_METHOD0(OnChannelListenError, void()); 63 MOCK_METHOD0(OnChannelListenError, void());
64 64
65 private: 65 private:
66 IPC::Channel* channel_; 66 IPC::Channel* channel_;
67 bool set_plugin_info_called_; 67 bool set_plugin_info_called_;
(...skipping 17 matching lines...) Expand all
85 }; 85 };
86 86
87 // Try to open a channel to the test plugin. Minimal plugin process spawning 87 // Try to open a channel to the test plugin. Minimal plugin process spawning
88 // test for the PluginService interface. 88 // test for the PluginService interface.
89 IN_PROC_BROWSER_TEST_F(PluginServiceTest, OpenChannelToPlugin) { 89 IN_PROC_BROWSER_TEST_F(PluginServiceTest, OpenChannelToPlugin) {
90 MockPluginProcessHostClient mock_client; 90 MockPluginProcessHostClient mock_client;
91 PluginService::GetInstance()->OpenChannelToNpapiPlugin( 91 PluginService::GetInstance()->OpenChannelToNpapiPlugin(
92 0, 0, GURL(), kNPAPITestPluginMimeType, &mock_client); 92 0, 0, GURL(), kNPAPITestPluginMimeType, &mock_client);
93 ui_test_utils::RunMessageLoop(); 93 ui_test_utils::RunMessageLoop();
94 } 94 }
OLDNEW
« no previous file with comments | « content/browser/plugin_process_host.h ('k') | content/browser/ppapi_broker_process_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698