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

Unified Diff: webrtc/api/webrtcsession_unittest.cc

Issue 1844803002: Modify PeerConnection for end-to-end QuicDataChannel usage (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Sync to upstream after landing QUIC data channel and QUIC transport CLs Created 4 years, 8 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/api/webrtcsession.cc ('k') | webrtc/media/base/mediaengine.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/api/webrtcsession_unittest.cc
diff --git a/webrtc/api/webrtcsession_unittest.cc b/webrtc/api/webrtcsession_unittest.cc
index 5e9b0390aa9d210af61009eb5cb8d8cc5d762506..20bdbd696fa4079e832aaf05b5ef5a6113d845e2 100644
--- a/webrtc/api/webrtcsession_unittest.cc
+++ b/webrtc/api/webrtcsession_unittest.cc
@@ -548,6 +548,8 @@ class WebRtcSessionTest
if (session_->data_channel_type() == cricket::DCT_SCTP && data_channel_) {
session_options->data_channel_type = cricket::DCT_SCTP;
+ } else if (session_->data_channel_type() == cricket::DCT_QUIC) {
+ session_options->data_channel_type = cricket::DCT_QUIC;
}
}
@@ -563,6 +565,8 @@ class WebRtcSessionTest
if (session_->data_channel_type() == cricket::DCT_SCTP) {
session_options->data_channel_type = cricket::DCT_SCTP;
+ } else if (session_->data_channel_type() == cricket::DCT_QUIC) {
+ session_options->data_channel_type = cricket::DCT_QUIC;
}
}
@@ -4277,6 +4281,26 @@ TEST_P(WebRtcSessionTest, TestRenegotiateNewMediaWithCandidatesSeparated) {
SetLocalDescriptionWithoutError(answer);
}
+#ifdef HAVE_QUIC
+TEST_P(WebRtcSessionTest, TestUseQuic) {
+ configuration_.enable_quic = true;
+ InitWithDtls(GetParam());
+ EXPECT_TRUE(session_->data_channel_type() == cricket::DCT_QUIC);
+ SessionDescriptionInterface* offer = CreateOffer();
+ ASSERT_TRUE(offer);
+ ASSERT_TRUE(offer->description());
+ SetLocalDescriptionWithoutError(offer);
+ cricket::MediaSessionOptions options;
+ options.recv_audio = true;
+ options.recv_video = true;
+ SessionDescriptionInterface* answer =
+ CreateRemoteAnswer(offer, options, cricket::SEC_DISABLED);
+ ASSERT_TRUE(answer);
+ ASSERT_TRUE(answer->description());
+ SetRemoteDescriptionWithoutError(answer);
+}
+#endif // HAVE_QUIC
+
// Flaky on Win and Mac only. See webrtc:4943
#if defined(WEBRTC_WIN) || defined(WEBRTC_MAC)
#define MAYBE_TestRtxRemovedByCreateAnswer DISABLED_TestRtxRemovedByCreateAnswer
« no previous file with comments | « webrtc/api/webrtcsession.cc ('k') | webrtc/media/base/mediaengine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698