| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <utility> | 5 #include <utility> |
| 6 | 6 |
| 7 #include "base/base64.h" | 7 #include "base/base64.h" |
| 8 #include "base/files/file_util.h" | 8 #include "base/files/file_util.h" |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 323 network_settings, protocol::TransportRole::SERVER)); | 323 network_settings, protocol::TransportRole::SERVER)); |
| 324 scoped_ptr<protocol::SessionManager> session_manager( | 324 scoped_ptr<protocol::SessionManager> session_manager( |
| 325 new protocol::JingleSessionManager(host_signaling_.get())); | 325 new protocol::JingleSessionManager(host_signaling_.get())); |
| 326 session_manager->set_protocol_config(protocol_config_->Clone()); | 326 session_manager->set_protocol_config(protocol_config_->Clone()); |
| 327 | 327 |
| 328 // Encoder runs on a separate thread, main thread is used for everything | 328 // Encoder runs on a separate thread, main thread is used for everything |
| 329 // else. | 329 // else. |
| 330 host_.reset(new ChromotingHost( | 330 host_.reset(new ChromotingHost( |
| 331 &desktop_environment_factory_, std::move(session_manager), | 331 &desktop_environment_factory_, std::move(session_manager), |
| 332 transport_context, host_thread_.task_runner(), | 332 transport_context, host_thread_.task_runner(), |
| 333 host_thread_.task_runner(), capture_thread_.task_runner(), | 333 encode_thread_.task_runner())); |
| 334 encode_thread_.task_runner(), host_thread_.task_runner(), | |
| 335 host_thread_.task_runner())); | |
| 336 | 334 |
| 337 base::FilePath certs_dir(net::GetTestCertsDirectory()); | 335 base::FilePath certs_dir(net::GetTestCertsDirectory()); |
| 338 | 336 |
| 339 std::string host_cert; | 337 std::string host_cert; |
| 340 ASSERT_TRUE(base::ReadFileToString( | 338 ASSERT_TRUE(base::ReadFileToString( |
| 341 certs_dir.AppendASCII("unittest.selfsigned.der"), &host_cert)); | 339 certs_dir.AppendASCII("unittest.selfsigned.der"), &host_cert)); |
| 342 | 340 |
| 343 base::FilePath key_path = certs_dir.AppendASCII("unittest.key.bin"); | 341 base::FilePath key_path = certs_dir.AppendASCII("unittest.key.bin"); |
| 344 std::string key_string; | 342 std::string key_string; |
| 345 ASSERT_TRUE(base::ReadFileToString(key_path, &key_string)); | 343 ASSERT_TRUE(base::ReadFileToString(key_path, &key_string)); |
| (...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 631 | 629 |
| 632 TEST_P(ProtocolPerfTest, TotalLatencyIce) { | 630 TEST_P(ProtocolPerfTest, TotalLatencyIce) { |
| 633 MeasureTotalLatency(false); | 631 MeasureTotalLatency(false); |
| 634 } | 632 } |
| 635 | 633 |
| 636 TEST_P(ProtocolPerfTest, TotalLatencyWebrtc) { | 634 TEST_P(ProtocolPerfTest, TotalLatencyWebrtc) { |
| 637 MeasureTotalLatency(true); | 635 MeasureTotalLatency(true); |
| 638 } | 636 } |
| 639 | 637 |
| 640 } // namespace remoting | 638 } // namespace remoting |
| OLD | NEW |