Chromium Code Reviews| Index: remoting/protocol/connection_unittest.cc |
| diff --git a/remoting/protocol/connection_unittest.cc b/remoting/protocol/connection_unittest.cc |
| index aba7ba3e1735ac60f0ac3aa887a738f8d9ef7875..d42e51978954e0db2dccc2bbeebf46af9908a3fc 100644 |
| --- a/remoting/protocol/connection_unittest.cc |
| +++ b/remoting/protocol/connection_unittest.cc |
| @@ -348,5 +348,26 @@ TEST_P(ConnectionTest, VideoWithSlowSignaling) { |
| WaitFirstVideoFrame(); |
| } |
| +TEST_P(ConnectionTest, DestroyOnIncomingMessage) { |
| + Connect(); |
| + |
| + KeyEvent event; |
| + event.set_usb_keycode(3); |
| + event.set_pressed(true); |
| + |
| + base::RunLoop run_loop; |
| + |
| + EXPECT_CALL(host_event_handler_, |
| + OnInputEventReceived(host_connection_.get(), _)); |
| + EXPECT_CALL(host_input_stub_, InjectKeyEvent(EqualsKeyEvent(event))) |
| + .WillOnce(/*DoAll(InvokeWithoutArgs(this, &ConnectionTest::DestroyHost),*/ |
|
Jamie
2016/07/23 00:03:48
Remove the comment?
Sergey Ulanov
2016/07/23 06:30:03
Duh, this line is not supposed to be commented, so
Sergey Ulanov
2016/07/23 06:31:33
On 2016/07/23 06:30:03, Sergey Ulanov wrote:
> On
|
| + QuitRunLoop(&run_loop)); |
| + |
| + // Send key event from the client. |
| + client_connection_->input_stub()->InjectKeyEvent(event); |
| + |
| + run_loop.Run(); |
| +} |
| + |
| } // namespace protocol |
| } // namespace remoting |