StreamDataCounters::last_packet_received_timestamp_ms added.
This a standard stat: https://w3c.github.io/webrtc-stats/#dom-rtcinboundrtpstreamstats-lastpacketreceivedtimestamp This is collected by StreamStatisticianImpl. A follow-up CL with plumb it to the RTCStatsCollector. Bug: webrtc:10449 Change-Id: I44e7f4735f9df78704ce21198f52e66d11e63740 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/130479 Reviewed-by: Åsa Persson <asapersson@webrtc.org> Commit-Queue: Henrik Boström <hbos@webrtc.org> Cr-Commit-Position: refs/heads/master@{#27416}
This commit is contained in:
committed by
Commit Bot
parent
cf2df2fb97
commit
cb755b001c
@ -605,6 +605,19 @@ TEST_F(ReceiveStatisticsTest, RtpCallbacks) {
|
||||
callback.Matches(5, kSsrc1, expected);
|
||||
}
|
||||
|
||||
TEST_F(ReceiveStatisticsTest, LastPacketReceivedTimestamp) {
|
||||
RtpTestCallback callback;
|
||||
receive_statistics_ = ReceiveStatistics::Create(&clock_, nullptr, &callback);
|
||||
|
||||
clock_.AdvanceTimeMilliseconds(42);
|
||||
receive_statistics_->OnRtpPacket(packet1_);
|
||||
EXPECT_EQ(42, callback.stats_.last_packet_received_timestamp_ms);
|
||||
|
||||
clock_.AdvanceTimeMilliseconds(3);
|
||||
receive_statistics_->OnRtpPacket(packet1_);
|
||||
EXPECT_EQ(45, callback.stats_.last_packet_received_timestamp_ms);
|
||||
}
|
||||
|
||||
TEST_F(ReceiveStatisticsTest, RtpCallbacksFecFirst) {
|
||||
RtpTestCallback callback;
|
||||
receive_statistics_ = ReceiveStatistics::Create(&clock_, nullptr, &callback);
|
||||
|
||||
Reference in New Issue
Block a user