Index: webrtc/p2p/base/p2ptransportchannel_unittest.cc |
diff --git a/webrtc/p2p/base/p2ptransportchannel_unittest.cc b/webrtc/p2p/base/p2ptransportchannel_unittest.cc |
index 6c26704388b8a86f50d78c079560bf568e94a83a..e5e63a3fa0c23d212a17eccb3c8dd7915c4fa49f 100644 |
--- a/webrtc/p2p/base/p2ptransportchannel_unittest.cc |
+++ b/webrtc/p2p/base/p2ptransportchannel_unittest.cc |
@@ -1071,6 +1071,16 @@ TEST_F(P2PTransportChannelTest, HandleUfragPwdChange) { |
DestroyChannels(); |
} |
+// Same as above test, but with a symmetric NAT. |
+// We should end up with relay<->prflx candidate pairs, with generation "1". |
+TEST_F(P2PTransportChannelTest, HandleUfragPwdChangeSymmetricNat) { |
+ ConfigureEndpoints(NAT_SYMMETRIC, NAT_SYMMETRIC, kDefaultPortAllocatorFlags, |
+ kDefaultPortAllocatorFlags); |
+ CreateChannels(1); |
+ TestHandleIceUfragPasswordChanged(); |
+ DestroyChannels(); |
+} |
+ |
// Test the operation of GetStats. |
TEST_F(P2PTransportChannelTest, GetStats) { |
ConfigureEndpoints(OPEN, OPEN, kDefaultPortAllocatorFlags, |
@@ -1333,6 +1343,11 @@ TEST_F(P2PTransportChannelTest, TestTcpConnectionsFromActiveToPassive) { |
SetAllowTcpListen(0, true); // actpass. |
SetAllowTcpListen(1, false); // active. |
+ // We want SetRemoteIceCredentials to be called as it normally would. |
+ // Otherwise we won't know what credentials to use for the expected |
+ // prflx TCP candidates. |
+ set_remote_ice_credential_source(FROM_SETICECREDENTIALS); |
+ |
// Pause candidate so we could verify the candidate properties. |
PauseCandidates(0); |
PauseCandidates(1); |
@@ -1627,6 +1642,7 @@ class P2PTransportChannelSameNatTest : public P2PTransportChannelTestBase { |
static_cast<rtc::NATType>(nat_type - NAT_FULL_CONE)); |
ConfigureEndpoint(outer_nat, 0, config1); |
ConfigureEndpoint(outer_nat, 1, config2); |
+ set_remote_ice_credential_source(FROM_SETICECREDENTIALS); |
} |
void ConfigureEndpoint(rtc::NATSocketServer::Translator* nat, |
int endpoint, Config config) { |