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

Side by Side Diff: remoting/protocol/channel_multiplexer_unittest.cc

Issue 1394803004: Don't use base::MessageLoop::{Quit,QuitClosure} in remoting/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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
« no previous file with comments | « remoting/protocol/authenticator_test_base.cc ('k') | remoting/protocol/connection_tester.cc » ('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 #include "remoting/protocol/channel_multiplexer.h" 5 #include "remoting/protocol/channel_multiplexer.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "net/base/net_errors.h" 10 #include "net/base/net_errors.h"
(...skipping 16 matching lines...) Expand all
27 27
28 const int kMessageSize = 1024; 28 const int kMessageSize = 1024;
29 const int kMessages = 100; 29 const int kMessages = 100;
30 const char kMuxChannelName[] = "mux"; 30 const char kMuxChannelName[] = "mux";
31 31
32 const char kTestChannelName[] = "test"; 32 const char kTestChannelName[] = "test";
33 const char kTestChannelName2[] = "test2"; 33 const char kTestChannelName2[] = "test2";
34 34
35 35
36 void QuitCurrentThread() { 36 void QuitCurrentThread() {
37 base::MessageLoop::current()->PostTask(FROM_HERE, 37 base::MessageLoop::current()->PostTask(
38 base::MessageLoop::QuitClosure()); 38 FROM_HERE, base::MessageLoop::QuitWhenIdleClosure());
39 } 39 }
40 40
41 class MockSocketCallback { 41 class MockSocketCallback {
42 public: 42 public:
43 MOCK_METHOD1(OnDone, void(int result)); 43 MOCK_METHOD1(OnDone, void(int result));
44 }; 44 };
45 45
46 class MockConnectCallback { 46 class MockConnectCallback {
47 public: 47 public:
48 MOCK_METHOD1(OnConnectedPtr, void(P2PStreamSocket* socket)); 48 MOCK_METHOD1(OnConnectedPtr, void(P2PStreamSocket* socket));
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 .WillOnce(InvokeWithoutArgs( 365 .WillOnce(InvokeWithoutArgs(
366 this, &ChannelMultiplexerTest::DeleteAfterSessionFail)); 366 this, &ChannelMultiplexerTest::DeleteAfterSessionFail));
367 EXPECT_CALL(cb2, OnConnectedPtr(_)) 367 EXPECT_CALL(cb2, OnConnectedPtr(_))
368 .Times(0); 368 .Times(0);
369 369
370 base::RunLoop().RunUntilIdle(); 370 base::RunLoop().RunUntilIdle();
371 } 371 }
372 372
373 } // namespace protocol 373 } // namespace protocol
374 } // namespace remoting 374 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/authenticator_test_base.cc ('k') | remoting/protocol/connection_tester.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698