| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 <memory> | 5 #include <memory> |
| 6 #include <sstream> | 6 #include <sstream> |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/at_exit.h" | 9 #include "base/at_exit.h" |
| 10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
| (...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 220 error_msg); | 220 error_msg); |
| 221 } | 221 } |
| 222 | 222 |
| 223 TEST_F(LoggingTest, ProtocolControl) { | 223 TEST_F(LoggingTest, ProtocolControl) { |
| 224 BlimpMessage base_msg; | 224 BlimpMessage base_msg; |
| 225 | 225 |
| 226 BlimpMessage start_connection_msg = base_msg; | 226 BlimpMessage start_connection_msg = base_msg; |
| 227 start_connection_msg.mutable_protocol_control()->mutable_start_connection(); | 227 start_connection_msg.mutable_protocol_control()->mutable_start_connection(); |
| 228 start_connection_msg.mutable_protocol_control() | 228 start_connection_msg.mutable_protocol_control() |
| 229 ->mutable_start_connection() | 229 ->mutable_start_connection() |
| 230 ->set_client_token("token"); | 230 ->set_client_auth_token("token"); |
| 231 start_connection_msg.mutable_protocol_control() | 231 start_connection_msg.mutable_protocol_control() |
| 232 ->mutable_start_connection() | 232 ->mutable_start_connection() |
| 233 ->set_protocol_version(2); | 233 ->set_protocol_version(2); |
| 234 VerifyLogOutput( | 234 VerifyLogOutput( |
| 235 "type=PROTOCOL_CONTROL subtype=START_CONNECTION " | 235 "type=PROTOCOL_CONTROL subtype=START_CONNECTION " |
| 236 "client_token=\"token\" protocol_version=2", | 236 "client_token=\"token\" protocol_version=2", |
| 237 start_connection_msg); | 237 start_connection_msg); |
| 238 | 238 |
| 239 start_connection_msg.mutable_protocol_control()->mutable_checkpoint_ack(); | 239 start_connection_msg.mutable_protocol_control()->mutable_checkpoint_ack(); |
| 240 start_connection_msg.mutable_protocol_control() | 240 start_connection_msg.mutable_protocol_control() |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 313 // Test SET_TEXT. | 313 // Test SET_TEXT. |
| 314 message.mutable_ime()->set_type(ImeMessage::SET_TEXT); | 314 message.mutable_ime()->set_type(ImeMessage::SET_TEXT); |
| 315 message.mutable_ime()->set_ime_text("1234"); | 315 message.mutable_ime()->set_ime_text("1234"); |
| 316 VerifyLogOutput( | 316 VerifyLogOutput( |
| 317 "type=IME render_widget_id=1 subtype=SET_TEXT ime_text(length)=4", | 317 "type=IME render_widget_id=1 subtype=SET_TEXT ime_text(length)=4", |
| 318 message); | 318 message); |
| 319 } | 319 } |
| 320 | 320 |
| 321 } // namespace | 321 } // namespace |
| 322 } // namespace blimp | 322 } // namespace blimp |
| OLD | NEW |