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

Unified Diff: webrtc/video/end_to_end_tests.cc

Issue 1376673004: Add a PacketOptions struct to webrtc::Transport. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Comment added Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/transport.h ('k') | webrtc/video/video_quality_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/end_to_end_tests.cc
diff --git a/webrtc/video/end_to_end_tests.cc b/webrtc/video/end_to_end_tests.cc
index 6e08053f5baf1d990be238a25ed3e4d4b3a883e7..4133f74e3dd3486e01aca226430702487ca9d3f3 100644
--- a/webrtc/video/end_to_end_tests.cc
+++ b/webrtc/video/end_to_end_tests.cc
@@ -61,7 +61,9 @@ class EndToEndTest : public test::CallTest {
protected:
class UnusedTransport : public Transport {
private:
- bool SendRtp(const uint8_t* packet, size_t length) override {
+ bool SendRtp(const uint8_t* packet,
+ size_t length,
+ const PacketOptions& options) override {
ADD_FAILURE() << "Unexpected RTP sent.";
return false;
}
@@ -1348,13 +1350,17 @@ TEST_F(EndToEndTest, AssignsTransportSequenceNumbers) {
}
virtual ~RtpExtensionHeaderObserver() {}
- bool SendRtp(const uint8_t* data, size_t length) override {
+ bool SendRtp(const uint8_t* data,
+ size_t length,
+ const PacketOptions& options) override {
if (IsDone())
return false;
RTPHeader header;
EXPECT_TRUE(parser_->Parse(data, length, &header));
if (header.extension.hasTransportSequenceNumber) {
+ EXPECT_EQ(options.packet_id,
+ header.extension.transportSequenceNumber);
if (!streams_observed_.empty()) {
EXPECT_EQ(static_cast<uint16_t>(last_seq_ + 1),
header.extension.transportSequenceNumber);
@@ -1374,7 +1380,7 @@ TEST_F(EndToEndTest, AssignsTransportSequenceNumbers) {
if (IsDone())
done_->Set();
}
- return test::DirectTransport::SendRtp(data, length);
+ return test::DirectTransport::SendRtp(data, length, options);
}
bool IsDone() {
« no previous file with comments | « webrtc/transport.h ('k') | webrtc/video/video_quality_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698