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

Side by Side Diff: webrtc/p2p/base/p2ptransportchannel_unittest.cc

Issue 2087713002: When a remote candidate is added, update all prflx candidates. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 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
« no previous file with comments | « webrtc/p2p/base/p2ptransportchannel.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2009 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2009 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 ss_scope_(ss_.get()), 142 ss_scope_(ss_.get()),
143 stun_server_(cricket::TestStunServer::Create(main_, kStunAddr)), 143 stun_server_(cricket::TestStunServer::Create(main_, kStunAddr)),
144 turn_server_(main_, kTurnUdpIntAddr, kTurnUdpExtAddr), 144 turn_server_(main_, kTurnUdpIntAddr, kTurnUdpExtAddr),
145 relay_server_(main_, kRelayUdpIntAddr, kRelayUdpExtAddr, 145 relay_server_(main_, kRelayUdpIntAddr, kRelayUdpExtAddr,
146 kRelayTcpIntAddr, kRelayTcpExtAddr, 146 kRelayTcpIntAddr, kRelayTcpExtAddr,
147 kRelaySslTcpIntAddr, kRelaySslTcpExtAddr), 147 kRelaySslTcpIntAddr, kRelaySslTcpExtAddr),
148 socks_server1_(ss_.get(), kSocksProxyAddrs[0], 148 socks_server1_(ss_.get(), kSocksProxyAddrs[0],
149 ss_.get(), kSocksProxyAddrs[0]), 149 ss_.get(), kSocksProxyAddrs[0]),
150 socks_server2_(ss_.get(), kSocksProxyAddrs[1], 150 socks_server2_(ss_.get(), kSocksProxyAddrs[1],
151 ss_.get(), kSocksProxyAddrs[1]), 151 ss_.get(), kSocksProxyAddrs[1]),
152 clear_remote_candidates_ufrag_pwd_(false),
153 force_relay_(false) { 152 force_relay_(false) {
154 ep1_.role_ = cricket::ICEROLE_CONTROLLING; 153 ep1_.role_ = cricket::ICEROLE_CONTROLLING;
155 ep2_.role_ = cricket::ICEROLE_CONTROLLED; 154 ep2_.role_ = cricket::ICEROLE_CONTROLLED;
156 155
157 ServerAddresses stun_servers; 156 ServerAddresses stun_servers;
158 stun_servers.insert(kStunAddr); 157 stun_servers.insert(kStunAddr);
159 ep1_.allocator_.reset(new cricket::BasicPortAllocator( 158 ep1_.allocator_.reset(new cricket::BasicPortAllocator(
160 &ep1_.network_manager_, 159 &ep1_.network_manager_,
161 stun_servers, kRelayUdpIntAddr, kRelayTcpIntAddr, kRelaySslTcpIntAddr)); 160 stun_servers, kRelayUdpIntAddr, kRelayTcpIntAddr, kRelaySslTcpIntAddr));
162 ep2_.allocator_.reset(new cricket::BasicPortAllocator( 161 ep2_.allocator_.reset(new cricket::BasicPortAllocator(
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 "test content name", component, GetAllocator(endpoint)); 318 "test content name", component, GetAllocator(endpoint));
320 channel->SignalCandidateGathered.connect( 319 channel->SignalCandidateGathered.connect(
321 this, &P2PTransportChannelTestBase::OnCandidateGathered); 320 this, &P2PTransportChannelTestBase::OnCandidateGathered);
322 channel->SignalCandidatesRemoved.connect( 321 channel->SignalCandidatesRemoved.connect(
323 this, &P2PTransportChannelTestBase::OnCandidatesRemoved); 322 this, &P2PTransportChannelTestBase::OnCandidatesRemoved);
324 channel->SignalReadPacket.connect( 323 channel->SignalReadPacket.connect(
325 this, &P2PTransportChannelTestBase::OnReadPacket); 324 this, &P2PTransportChannelTestBase::OnReadPacket);
326 channel->SignalRoleConflict.connect( 325 channel->SignalRoleConflict.connect(
327 this, &P2PTransportChannelTestBase::OnRoleConflict); 326 this, &P2PTransportChannelTestBase::OnRoleConflict);
328 channel->SetIceCredentials(local_ice_ufrag, local_ice_pwd); 327 channel->SetIceCredentials(local_ice_ufrag, local_ice_pwd);
329 if (clear_remote_candidates_ufrag_pwd_) { 328 if (remote_ice_credential_source_ == FROM_SETICECREDENTIALS) {
330 // This only needs to be set if we're clearing them from the
331 // candidates. Some unit tests rely on this not being set.
332 channel->SetRemoteIceCredentials(remote_ice_ufrag, remote_ice_pwd); 329 channel->SetRemoteIceCredentials(remote_ice_ufrag, remote_ice_pwd);
333 } 330 }
334 channel->SetIceRole(GetEndpoint(endpoint)->ice_role()); 331 channel->SetIceRole(GetEndpoint(endpoint)->ice_role());
335 channel->SetIceTiebreaker(GetEndpoint(endpoint)->GetIceTiebreaker()); 332 channel->SetIceTiebreaker(GetEndpoint(endpoint)->GetIceTiebreaker());
336 channel->Connect(); 333 channel->Connect();
337 return channel; 334 return channel;
338 } 335 }
339 void DestroyChannels() { 336 void DestroyChannels() {
340 ep1_.cd1_.ch_.reset(); 337 ep1_.cd1_.ch_.reset();
341 ep2_.cd1_.ch_.reset(); 338 ep2_.cd1_.ch_.reset();
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
698 ed->save_candidates_ = false; 695 ed->save_candidates_ = false;
699 } 696 }
700 697
701 void OnMessage(rtc::Message* msg) { 698 void OnMessage(rtc::Message* msg) {
702 switch (msg->message_id) { 699 switch (msg->message_id) {
703 case MSG_ADD_CANDIDATES: { 700 case MSG_ADD_CANDIDATES: {
704 std::unique_ptr<CandidatesData> data( 701 std::unique_ptr<CandidatesData> data(
705 static_cast<CandidatesData*>(msg->pdata)); 702 static_cast<CandidatesData*>(msg->pdata));
706 cricket::P2PTransportChannel* rch = GetRemoteChannel(data->channel); 703 cricket::P2PTransportChannel* rch = GetRemoteChannel(data->channel);
707 for (auto& c : data->candidates) { 704 for (auto& c : data->candidates) {
708 if (clear_remote_candidates_ufrag_pwd_) { 705 if (remote_ice_credential_source_ != FROM_CANDIDATE) {
709 c.set_username(""); 706 c.set_username("");
710 c.set_password(""); 707 c.set_password("");
711 } 708 }
712 LOG(LS_INFO) << "Candidate(" << data->channel->component() << "->" 709 LOG(LS_INFO) << "Candidate(" << data->channel->component() << "->"
713 << rch->component() << "): " << c.ToString(); 710 << rch->component() << "): " << c.ToString();
714 rch->AddRemoteCandidate(c); 711 rch->AddRemoteCandidate(c);
715 } 712 }
716 break; 713 break;
717 } 714 }
718 case MSG_REMOVE_CANDIDATES: { 715 case MSG_REMOVE_CANDIDATES: {
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
779 return ep1_ch1(); 776 return ep1_ch1();
780 else if (ch == ep2_ch2()) 777 else if (ch == ep2_ch2())
781 return ep1_ch2(); 778 return ep1_ch2();
782 else 779 else
783 return NULL; 780 return NULL;
784 } 781 }
785 std::list<std::string>& GetPacketList(cricket::TransportChannel* ch) { 782 std::list<std::string>& GetPacketList(cricket::TransportChannel* ch) {
786 return GetChannelData(ch)->ch_packets_; 783 return GetChannelData(ch)->ch_packets_;
787 } 784 }
788 785
789 void set_clear_remote_candidates_ufrag_pwd(bool clear) { 786 enum RemoteIceCredentialSource { FROM_CANDIDATE, FROM_SETICECREDENTIALS };
Taylor Brandstetter 2016/06/21 00:33:05 I changed this method for readability. It wasn't c
790 clear_remote_candidates_ufrag_pwd_ = clear; 787
788 // How does the test pass ICE credentials to the P2PTransportChannel?
789 // On the candidate itself, or through SetIceCredentials?
790 // Goes through the candidate itself by default.
791 void set_remote_ice_credential_source(RemoteIceCredentialSource source) {
792 remote_ice_credential_source_ = source;
791 } 793 }
792 794
793 void set_force_relay(bool relay) { 795 void set_force_relay(bool relay) {
794 force_relay_ = relay; 796 force_relay_ = relay;
795 } 797 }
796 798
797 private: 799 private:
798 rtc::Thread* main_; 800 rtc::Thread* main_;
799 std::unique_ptr<rtc::PhysicalSocketServer> pss_; 801 std::unique_ptr<rtc::PhysicalSocketServer> pss_;
800 std::unique_ptr<rtc::VirtualSocketServer> vss_; 802 std::unique_ptr<rtc::VirtualSocketServer> vss_;
801 std::unique_ptr<rtc::NATSocketServer> nss_; 803 std::unique_ptr<rtc::NATSocketServer> nss_;
802 std::unique_ptr<rtc::FirewallSocketServer> ss_; 804 std::unique_ptr<rtc::FirewallSocketServer> ss_;
803 rtc::SocketServerScope ss_scope_; 805 rtc::SocketServerScope ss_scope_;
804 std::unique_ptr<cricket::TestStunServer> stun_server_; 806 std::unique_ptr<cricket::TestStunServer> stun_server_;
805 cricket::TestTurnServer turn_server_; 807 cricket::TestTurnServer turn_server_;
806 cricket::TestRelayServer relay_server_; 808 cricket::TestRelayServer relay_server_;
807 rtc::SocksProxyServer socks_server1_; 809 rtc::SocksProxyServer socks_server1_;
808 rtc::SocksProxyServer socks_server2_; 810 rtc::SocksProxyServer socks_server2_;
809 Endpoint ep1_; 811 Endpoint ep1_;
810 Endpoint ep2_; 812 Endpoint ep2_;
811 bool clear_remote_candidates_ufrag_pwd_; 813 RemoteIceCredentialSource remote_ice_credential_source_ = FROM_CANDIDATE;
812 bool force_relay_; 814 bool force_relay_;
813 }; 815 };
814 816
815 // The tests have only a few outcomes, which we predefine. 817 // The tests have only a few outcomes, which we predefine.
816 const P2PTransportChannelTestBase::Result P2PTransportChannelTestBase:: 818 const P2PTransportChannelTestBase::Result P2PTransportChannelTestBase::
817 kLocalUdpToLocalUdp("local", "udp", "local", "udp", 819 kLocalUdpToLocalUdp("local", "udp", "local", "udp",
818 "local", "udp", "local", "udp", 1000); 820 "local", "udp", "local", "udp", 1000);
819 const P2PTransportChannelTestBase::Result P2PTransportChannelTestBase:: 821 const P2PTransportChannelTestBase::Result P2PTransportChannelTestBase::
820 kLocalUdpToStunUdp("local", "udp", "stun", "udp", 822 kLocalUdpToStunUdp("local", "udp", "stun", "udp",
821 "local", "udp", "stun", "udp", 1000); 823 "local", "udp", "stun", "udp", 1000);
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
880 GetEndpoint(1)->allocator_->AddTurnServer(turn_server); 882 GetEndpoint(1)->allocator_->AddTurnServer(turn_server);
881 883
882 int delay = kMinimumStepDelay; 884 int delay = kMinimumStepDelay;
883 ConfigureEndpoint(0, config1); 885 ConfigureEndpoint(0, config1);
884 SetAllocatorFlags(0, allocator_flags1); 886 SetAllocatorFlags(0, allocator_flags1);
885 SetAllocationStepDelay(0, delay); 887 SetAllocationStepDelay(0, delay);
886 ConfigureEndpoint(1, config2); 888 ConfigureEndpoint(1, config2);
887 SetAllocatorFlags(1, allocator_flags2); 889 SetAllocatorFlags(1, allocator_flags2);
888 SetAllocationStepDelay(1, delay); 890 SetAllocationStepDelay(1, delay);
889 891
890 set_clear_remote_candidates_ufrag_pwd(true); 892 set_remote_ice_credential_source(FROM_SETICECREDENTIALS);
891 } 893 }
892 void ConfigureEndpoint(int endpoint, Config config) { 894 void ConfigureEndpoint(int endpoint, Config config) {
893 switch (config) { 895 switch (config) {
894 case OPEN: 896 case OPEN:
895 AddAddress(endpoint, kPublicAddrs[endpoint]); 897 AddAddress(endpoint, kPublicAddrs[endpoint]);
896 break; 898 break;
897 case NAT_FULL_CONE: 899 case NAT_FULL_CONE:
898 case NAT_ADDR_RESTRICTED: 900 case NAT_ADDR_RESTRICTED:
899 case NAT_PORT_RESTRICTED: 901 case NAT_PORT_RESTRICTED:
900 case NAT_SYMMETRIC: 902 case NAT_SYMMETRIC:
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
1098 EXPECT_GT(best_conn_info->rtt, 0U); 1100 EXPECT_GT(best_conn_info->rtt, 0U);
1099 DestroyChannels(); 1101 DestroyChannels();
1100 } 1102 }
1101 1103
1102 // Test that we properly create a connection on a STUN ping from unknown address 1104 // Test that we properly create a connection on a STUN ping from unknown address
1103 // when the signaling is slow. 1105 // when the signaling is slow.
1104 TEST_F(P2PTransportChannelTest, PeerReflexiveCandidateBeforeSignaling) { 1106 TEST_F(P2PTransportChannelTest, PeerReflexiveCandidateBeforeSignaling) {
1105 ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags, 1107 ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags,
1106 kDefaultPortAllocatorFlags); 1108 kDefaultPortAllocatorFlags);
1107 // Emulate no remote credentials coming in. 1109 // Emulate no remote credentials coming in.
1108 set_clear_remote_candidates_ufrag_pwd(false); 1110 set_remote_ice_credential_source(FROM_CANDIDATE);
1109 CreateChannels(1); 1111 CreateChannels(1);
1110 // Only have remote credentials come in for ep2, not ep1. 1112 // Only have remote credentials come in for ep2, not ep1.
1111 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[0], kIcePwd[0]); 1113 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[0], kIcePwd[0]);
1112 1114
1113 // Pause sending ep2's candidates to ep1 until ep1 receives the peer reflexive 1115 // Pause sending ep2's candidates to ep1 until ep1 receives the peer reflexive
1114 // candidate. 1116 // candidate.
1115 PauseCandidates(1); 1117 PauseCandidates(1);
1116 1118
1117 // The caller should have the best connection connected to the peer reflexive 1119 // The caller should have the best connection connected to the peer reflexive
1118 // candidate. 1120 // candidate.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
1150 EXPECT_EQ(best_connection, ep1_ch1()->best_connection()); 1152 EXPECT_EQ(best_connection, ep1_ch1()->best_connection());
1151 DestroyChannels(); 1153 DestroyChannels();
1152 } 1154 }
1153 1155
1154 // Test that we properly create a connection on a STUN ping from unknown address 1156 // Test that we properly create a connection on a STUN ping from unknown address
1155 // when the signaling is slow and the end points are behind NAT. 1157 // when the signaling is slow and the end points are behind NAT.
1156 TEST_F(P2PTransportChannelTest, PeerReflexiveCandidateBeforeSignalingWithNAT) { 1158 TEST_F(P2PTransportChannelTest, PeerReflexiveCandidateBeforeSignalingWithNAT) {
1157 ConfigureEndpoints(OPEN, NAT_SYMMETRIC, kDefaultPortAllocatorFlags, 1159 ConfigureEndpoints(OPEN, NAT_SYMMETRIC, kDefaultPortAllocatorFlags,
1158 kDefaultPortAllocatorFlags); 1160 kDefaultPortAllocatorFlags);
1159 // Emulate no remote credentials coming in. 1161 // Emulate no remote credentials coming in.
1160 set_clear_remote_candidates_ufrag_pwd(false); 1162 set_remote_ice_credential_source(FROM_CANDIDATE);
1161 CreateChannels(1); 1163 CreateChannels(1);
1162 // Only have remote credentials come in for ep2, not ep1. 1164 // Only have remote credentials come in for ep2, not ep1.
1163 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[0], kIcePwd[0]); 1165 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[0], kIcePwd[0]);
1164 // Pause sending ep2's candidates to ep1 until ep1 receives the peer reflexive 1166 // Pause sending ep2's candidates to ep1 until ep1 receives the peer reflexive
1165 // candidate. 1167 // candidate.
1166 PauseCandidates(1); 1168 PauseCandidates(1);
1167 1169
1168 // The caller should have the best connection connected to the peer reflexive 1170 // The caller should have the best connection connected to the peer reflexive
1169 // candidate. 1171 // candidate.
1170 WAIT(ep1_ch1()->best_connection() != NULL, 2000); 1172 WAIT(ep1_ch1()->best_connection() != NULL, 2000);
(...skipping 22 matching lines...) Expand all
1193 const cricket::Connection* best_connection = NULL; 1195 const cricket::Connection* best_connection = NULL;
1194 WAIT((best_connection = ep2_ch1()->best_connection()) != NULL, 2000); 1196 WAIT((best_connection = ep2_ch1()->best_connection()) != NULL, 2000);
1195 1197
1196 // Wait to verify the connection is not culled. 1198 // Wait to verify the connection is not culled.
1197 WAIT(ep1_ch1()->writable(), 2000); 1199 WAIT(ep1_ch1()->writable(), 2000);
1198 EXPECT_EQ(ep2_ch1()->best_connection(), best_connection); 1200 EXPECT_EQ(ep2_ch1()->best_connection(), best_connection);
1199 EXPECT_EQ("prflx", ep1_ch1()->best_connection()->remote_candidate().type()); 1201 EXPECT_EQ("prflx", ep1_ch1()->best_connection()->remote_candidate().type());
1200 DestroyChannels(); 1202 DestroyChannels();
1201 } 1203 }
1202 1204
1205 // Test that we properly create a connection on a STUN ping from unknown address
1206 // when the signaling is slow, even if the new candidate is created due to the
1207 // remote peer doing an ICE restart, pairing this candidate across generations.
1208 //
1209 // Previously this wasn't working due to a bug where the peer reflexive
1210 // candidate was only updated for the newest generation candidate pairs, and
1211 // not older-generation candidate pairs created by pairing candidates across
1212 // generations. This resulted in the old-generation prflx candidate being
1213 // prioritized above new-generation candidate pairs.
1214 TEST_F(P2PTransportChannelTest,
1215 PeerReflexiveCandidateBeforeSignalingWithIceRestart) {
1216 ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags,
1217 kDefaultPortAllocatorFlags);
1218 // Only gather relay candidates, so that when the prflx candidate arrives
1219 // it's prioritized above the current candidate pair.
1220 GetEndpoint(0)->allocator_->set_candidate_filter(cricket::CF_RELAY);
1221 GetEndpoint(1)->allocator_->set_candidate_filter(cricket::CF_RELAY);
1222 // Setting this allows us to control when SetRemoteIceCredentials is called.
1223 set_remote_ice_credential_source(FROM_CANDIDATE);
1224 CreateChannels(1);
1225 // Wait for the initial connection to be made.
1226 ep1_ch1()->SetRemoteIceCredentials(kIceUfrag[1], kIcePwd[1]);
1227 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[0], kIcePwd[0]);
1228 EXPECT_TRUE_WAIT(ep1_ch1()->receiving() && ep1_ch1()->writable() &&
1229 ep2_ch1()->receiving() && ep2_ch1()->writable(),
1230 kDefaultTimeout);
1231
1232 // Simulate an ICE restart on ep2, but don't signal the candidate or new
1233 // ICE credentials until after a prflx connection has been made.
1234 PauseCandidates(1);
1235 ep2_ch1()->SetIceCredentials(kIceUfrag[3], kIcePwd[3]);
1236 ep1_ch1()->SetRemoteIceCredentials(kIceUfrag[3], kIcePwd[3]);
1237 ep2_ch1()->MaybeStartGathering();
1238
1239 // The caller should have the best connection connected to the peer reflexive
1240 // candidate.
1241 EXPECT_EQ_WAIT("prflx",
1242 ep1_ch1()->best_connection()->remote_candidate().type(),
1243 kDefaultTimeout);
1244 const cricket::Connection* prflx_best_connection =
1245 ep1_ch1()->best_connection();
1246
1247 // Now simulate the ICE restart on ep1.
1248 ep1_ch1()->SetIceCredentials(kIceUfrag[2], kIcePwd[2]);
1249 ep2_ch1()->SetRemoteIceCredentials(kIceUfrag[2], kIcePwd[2]);
1250 ep1_ch1()->MaybeStartGathering();
1251
1252 // Finally send the candidates from ep2's ICE restart and verify that ep1 uses
1253 // their information to update the peer reflexive candidate.
1254 ResumeCandidates(1);
1255
1256 EXPECT_EQ_WAIT("relay",
1257 ep1_ch1()->best_connection()->remote_candidate().type(),
1258 kDefaultTimeout);
1259 EXPECT_EQ(prflx_best_connection, ep1_ch1()->best_connection());
1260 DestroyChannels();
1261 }
1262
1203 // Test that if remote candidates don't have ufrag and pwd, we still work. 1263 // Test that if remote candidates don't have ufrag and pwd, we still work.
1204 TEST_F(P2PTransportChannelTest, RemoteCandidatesWithoutUfragPwd) { 1264 TEST_F(P2PTransportChannelTest, RemoteCandidatesWithoutUfragPwd) {
1205 set_clear_remote_candidates_ufrag_pwd(true); 1265 set_remote_ice_credential_source(FROM_SETICECREDENTIALS);
1206 ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags, 1266 ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags,
1207 kDefaultPortAllocatorFlags); 1267 kDefaultPortAllocatorFlags);
1208 CreateChannels(1); 1268 CreateChannels(1);
1209 const cricket::Connection* best_connection = NULL; 1269 const cricket::Connection* best_connection = NULL;
1210 // Wait until the callee's connections are created. 1270 // Wait until the callee's connections are created.
1211 WAIT((best_connection = ep2_ch1()->best_connection()) != NULL, 1000); 1271 WAIT((best_connection = ep2_ch1()->best_connection()) != NULL, 1000);
1212 // Wait to see if they get culled; they shouldn't. 1272 // Wait to see if they get culled; they shouldn't.
1213 WAIT(ep2_ch1()->best_connection() != best_connection, 1000); 1273 WAIT(ep2_ch1()->best_connection() != best_connection, 1000);
1214 EXPECT_TRUE(ep2_ch1()->best_connection() == best_connection); 1274 EXPECT_TRUE(ep2_ch1()->best_connection() == best_connection);
1215 DestroyChannels(); 1275 DestroyChannels();
(...skipping 1752 matching lines...) Expand 10 before | Expand all | Expand 10 after
2968 3028
2969 // TCP Relay/Relay is the next. 3029 // TCP Relay/Relay is the next.
2970 VerifyNextPingableConnection(cricket::RELAY_PORT_TYPE, 3030 VerifyNextPingableConnection(cricket::RELAY_PORT_TYPE,
2971 cricket::RELAY_PORT_TYPE, 3031 cricket::RELAY_PORT_TYPE,
2972 cricket::TCP_PROTOCOL_NAME); 3032 cricket::TCP_PROTOCOL_NAME);
2973 3033
2974 // Finally, Local/Relay will be pinged. 3034 // Finally, Local/Relay will be pinged.
2975 VerifyNextPingableConnection(cricket::LOCAL_PORT_TYPE, 3035 VerifyNextPingableConnection(cricket::LOCAL_PORT_TYPE,
2976 cricket::RELAY_PORT_TYPE); 3036 cricket::RELAY_PORT_TYPE);
2977 } 3037 }
OLDNEW
« no previous file with comments | « webrtc/p2p/base/p2ptransportchannel.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698