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

Side by Side Diff: ipc/ipc_channel_posix_unittest.cc

Issue 11419224: Add missing (and remove superfluous) 'explicit' from constructors. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase + remove non-straightforward changes Created 7 years, 11 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 | « gpu/tools/compositor_model_bench/forward_render_model.h ('k') | ipc/ipc_channel_proxy.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) 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 // These tests are POSIX only. 5 // These tests are POSIX only.
6 6
7 #include "ipc/ipc_channel_posix.h" 7 #include "ipc/ipc_channel_posix.h"
8 8
9 #include <fcntl.h> 9 #include <fcntl.h>
10 #include <sys/socket.h> 10 #include <sys/socket.h>
(...skipping 20 matching lines...) Expand all
31 public: 31 public:
32 enum STATUS { 32 enum STATUS {
33 DISCONNECTED, 33 DISCONNECTED,
34 MESSAGE_RECEIVED, 34 MESSAGE_RECEIVED,
35 CHANNEL_ERROR, 35 CHANNEL_ERROR,
36 CONNECTED, 36 CONNECTED,
37 DENIED, 37 DENIED,
38 LISTEN_ERROR 38 LISTEN_ERROR
39 }; 39 };
40 40
41 IPCChannelPosixTestListener(bool quit_only_on_message) 41 explicit IPCChannelPosixTestListener(bool quit_only_on_message)
42 : status_(DISCONNECTED), quit_only_on_message_(quit_only_on_message) {} 42 : status_(DISCONNECTED), quit_only_on_message_(quit_only_on_message) {}
43 43
44 virtual ~IPCChannelPosixTestListener() {} 44 virtual ~IPCChannelPosixTestListener() {}
45 45
46 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE { 46 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE {
47 EXPECT_EQ(message.type(), kQuitMessage); 47 EXPECT_EQ(message.type(), kQuitMessage);
48 status_ = MESSAGE_RECEIVED; 48 status_ = MESSAGE_RECEIVED;
49 QuitRunLoop(); 49 QuitRunLoop();
50 return true; 50 return true;
51 } 51 }
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after
418 // it. 418 // it.
419 bool connected = channel.Connect(); 419 bool connected = channel.Connect();
420 if (connected) { 420 if (connected) {
421 IPCChannelPosixTest::SpinRunLoop(TestTimeouts::action_max_timeout()); 421 IPCChannelPosixTest::SpinRunLoop(TestTimeouts::action_max_timeout());
422 EXPECT_EQ(IPCChannelPosixTestListener::CHANNEL_ERROR, listener.status()); 422 EXPECT_EQ(IPCChannelPosixTestListener::CHANNEL_ERROR, listener.status());
423 } else { 423 } else {
424 EXPECT_EQ(IPCChannelPosixTestListener::DISCONNECTED, listener.status()); 424 EXPECT_EQ(IPCChannelPosixTestListener::DISCONNECTED, listener.status());
425 } 425 }
426 return 0; 426 return 0;
427 } 427 }
OLDNEW
« no previous file with comments | « gpu/tools/compositor_model_bench/forward_render_model.h ('k') | ipc/ipc_channel_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698