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

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

Issue 2887183004: Ensure that remoting_unittests fail when playout delay > 0. (Closed)
Patch Set: fix failure on windows Created 3 years, 7 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 | « no previous file | remoting/protocol/webrtc_video_renderer_adapter.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first. 5 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first.
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 514 matching lines...) Expand 10 before | Expand all | Expand 10 after
525 run_loop.Run(); 525 run_loop.Run();
526 } 526 }
527 527
528 TEST_P(ConnectionTest, Video) { 528 TEST_P(ConnectionTest, Video) {
529 Connect(); 529 Connect();
530 530
531 std::unique_ptr<VideoStream> video_stream = 531 std::unique_ptr<VideoStream> video_stream =
532 host_connection_->StartVideoStream( 532 host_connection_->StartVideoStream(
533 base::MakeUnique<TestScreenCapturer>()); 533 base::MakeUnique<TestScreenCapturer>());
534 534
535 WaitNextVideoFrame(); 535 // Receive 5 frames.
536 for (int i = 0; i < 5; ++i) {
537 WaitNextVideoFrame();
538 }
536 } 539 }
537 540
538 // Verifies that the VideoStream doesn't loose any video frames while the 541 // Verifies that the VideoStream doesn't loose any video frames while the
539 // connection is being established. 542 // connection is being established.
540 TEST_P(ConnectionTest, VideoWithSlowSignaling) { 543 TEST_P(ConnectionTest, VideoWithSlowSignaling) {
541 // Add signaling delay to slow down connection handshake. 544 // Add signaling delay to slow down connection handshake.
542 host_session_->set_signaling_delay(base::TimeDelta::FromMilliseconds(100)); 545 host_session_->set_signaling_delay(base::TimeDelta::FromMilliseconds(100));
543 client_session_->set_signaling_delay(base::TimeDelta::FromMilliseconds(100)); 546 client_session_->set_signaling_delay(base::TimeDelta::FromMilliseconds(100));
544 547
545 Connect(); 548 Connect();
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
651 auto capturer = base::MakeUnique<TestScreenCapturer>(); 654 auto capturer = base::MakeUnique<TestScreenCapturer>();
652 capturer->FailNthFrame(1); 655 capturer->FailNthFrame(1);
653 auto video_stream = host_connection_->StartVideoStream(std::move(capturer)); 656 auto video_stream = host_connection_->StartVideoStream(std::move(capturer));
654 657
655 WaitNextVideoFrame(); 658 WaitNextVideoFrame();
656 WaitNextVideoFrame(); 659 WaitNextVideoFrame();
657 } 660 }
658 661
659 } // namespace protocol 662 } // namespace protocol
660 } // namespace remoting 663 } // namespace remoting
OLDNEW
« no previous file with comments | « no previous file | remoting/protocol/webrtc_video_renderer_adapter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698