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

Side by Side Diff: media/cast/rtcp/rtcp_unittest.cc

Issue 302913004: Cast: cancel re-sending if a later nack packet says the receiver doesn't want it anymore (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: variable renamed + comment added Created 6 years, 6 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 <stdint.h> 5 #include <stdint.h>
6 6
7 #include "base/test/simple_test_tick_clock.h" 7 #include "base/test/simple_test_tick_clock.h"
8 #include "media/cast/cast_defines.h" 8 #include "media/cast/cast_defines.h"
9 #include "media/cast/cast_environment.h" 9 #include "media/cast/cast_environment.h"
10 #include "media/cast/rtcp/mock_rtcp_receiver_feedback.h" 10 #include "media/cast/rtcp/mock_rtcp_receiver_feedback.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 virtual bool SendPackets( 101 virtual bool SendPackets(
102 const transport::SendPacketVector& packets) OVERRIDE { 102 const transport::SendPacketVector& packets) OVERRIDE {
103 return false; 103 return false;
104 } 104 }
105 105
106 virtual bool ResendPackets( 106 virtual bool ResendPackets(
107 const transport::SendPacketVector& packets) OVERRIDE { 107 const transport::SendPacketVector& packets) OVERRIDE {
108 return false; 108 return false;
109 } 109 }
110 110
111 virtual void CancelSendingPacket(
112 const transport::PacketKey& packet_key) OVERRIDE {
113 }
114
111 private: 115 private:
112 bool drop_packets_; 116 bool drop_packets_;
113 bool short_delay_; 117 bool short_delay_;
114 Rtcp* rtcp_; 118 Rtcp* rtcp_;
115 base::SimpleTestTickClock* testing_clock_; 119 base::SimpleTestTickClock* testing_clock_;
116 scoped_refptr<CastEnvironment> cast_environment_; 120 scoped_refptr<CastEnvironment> cast_environment_;
117 121
118 DISALLOW_COPY_AND_ASSIGN(LocalRtcpTransport); 122 DISALLOW_COPY_AND_ASSIGN(LocalRtcpTransport);
119 }; 123 };
120 124
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
534 base::TimeTicks out_3 = ConvertNtpToTimeTicks(ntp_seconds_3, ntp_fraction_3); 538 base::TimeTicks out_3 = ConvertNtpToTimeTicks(ntp_seconds_3, ntp_fraction_3);
535 EXPECT_EQ(input_time, out_3); // Verify inverse. 539 EXPECT_EQ(input_time, out_3); // Verify inverse.
536 540
537 // Verify delta. 541 // Verify delta.
538 EXPECT_EQ((out_3 - out_2), time_delta); 542 EXPECT_EQ((out_3 - out_2), time_delta);
539 EXPECT_NEAR((ntp_fraction_3 - ntp_fraction_2), 0xffffffff / 2, 1); 543 EXPECT_NEAR((ntp_fraction_3 - ntp_fraction_2), 0xffffffff / 2, 1);
540 } 544 }
541 545
542 } // namespace cast 546 } // namespace cast
543 } // namespace media 547 } // namespace media
OLDNEW
« no previous file with comments | « media/cast/rtcp/rtcp_sender_unittest.cc ('k') | media/cast/transport/pacing/mock_paced_packet_sender.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698