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

Unified Diff: webrtc/api/webrtcsession_unittest.cc

Issue 1956453003: Relanding: Implement RTCConfiguration.iceCandidatePoolSize. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fixing uninitialized variable (noticed by msan) Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/api/webrtcsession.cc ('k') | webrtc/p2p/base/candidate.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 34d82582c61ad54df6aa99641ae819e18dd74e6d..ae11b4613d86f3610c30822fb54c58005d0f6e56 100644
--- a/webrtc/api/webrtcsession_unittest.cc
+++ b/webrtc/api/webrtcsession_unittest.cc
@@ -405,12 +405,6 @@ class WebRtcSessionTest
void Init() { Init(nullptr); }
- void InitWithIceTransport(
- PeerConnectionInterface::IceTransportsType ice_transport_type) {
- configuration_.type = ice_transport_type;
- Init();
- }
-
void InitWithBundlePolicy(
PeerConnectionInterface::BundlePolicy bundle_policy) {
configuration_.bundle_policy = bundle_policy;
@@ -1525,50 +1519,6 @@ TEST_F(WebRtcSessionTest, MAYBE_TestStunError) {
EXPECT_EQ(6u, observer_.mline_1_candidates_.size());
}
-// Test session delivers no candidates gathered when constraint set to "none".
-TEST_F(WebRtcSessionTest, TestIceTransportsNone) {
- AddInterface(rtc::SocketAddress(kClientAddrHost1, kClientAddrPort));
- InitWithIceTransport(PeerConnectionInterface::kNone);
- SendAudioVideoStream1();
- InitiateCall();
- EXPECT_TRUE_WAIT(observer_.oncandidatesready_, kIceCandidatesTimeout);
- EXPECT_EQ(0u, observer_.mline_0_candidates_.size());
- EXPECT_EQ(0u, observer_.mline_1_candidates_.size());
-}
-
-// Test session delivers only relay candidates gathered when constaint set to
-// "relay".
-TEST_F(WebRtcSessionTest, TestIceTransportsRelay) {
- AddInterface(rtc::SocketAddress(kClientAddrHost1, kClientAddrPort));
- ConfigureAllocatorWithTurn();
- InitWithIceTransport(PeerConnectionInterface::kRelay);
- SendAudioVideoStream1();
- InitiateCall();
- EXPECT_TRUE_WAIT(observer_.oncandidatesready_, kIceCandidatesTimeout);
- EXPECT_EQ(2u, observer_.mline_0_candidates_.size());
- EXPECT_EQ(2u, observer_.mline_1_candidates_.size());
- for (size_t i = 0; i < observer_.mline_0_candidates_.size(); ++i) {
- EXPECT_EQ(cricket::RELAY_PORT_TYPE,
- observer_.mline_0_candidates_[i].type());
- }
- for (size_t i = 0; i < observer_.mline_1_candidates_.size(); ++i) {
- EXPECT_EQ(cricket::RELAY_PORT_TYPE,
- observer_.mline_1_candidates_[i].type());
- }
-}
-
-// Test session delivers all candidates gathered when constaint set to "all".
-TEST_F(WebRtcSessionTest, TestIceTransportsAll) {
- AddInterface(rtc::SocketAddress(kClientAddrHost1, kClientAddrPort));
- InitWithIceTransport(PeerConnectionInterface::kAll);
- SendAudioVideoStream1();
- InitiateCall();
- EXPECT_TRUE_WAIT(observer_.oncandidatesready_, kIceCandidatesTimeout);
- // Host + STUN. By default allocator is disabled to gather relay candidates.
- EXPECT_EQ(4u, observer_.mline_0_candidates_.size());
- EXPECT_EQ(4u, observer_.mline_1_candidates_.size());
-}
-
TEST_F(WebRtcSessionTest, SetSdpFailedOnInvalidSdp) {
Init();
SessionDescriptionInterface* offer = NULL;
« no previous file with comments | « webrtc/api/webrtcsession.cc ('k') | webrtc/p2p/base/candidate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698