Index: webrtc/p2p/client/portallocator_unittest.cc |
diff --git a/webrtc/p2p/client/portallocator_unittest.cc b/webrtc/p2p/client/portallocator_unittest.cc |
index 92f995a3d7787550753eec544550b8fcb2371c24..5fd200f59dd7997540ec0f93dedb2b724be04201 100644 |
--- a/webrtc/p2p/client/portallocator_unittest.cc |
+++ b/webrtc/p2p/client/portallocator_unittest.cc |
@@ -585,6 +585,18 @@ TEST_F(PortAllocatorTest, TestGetAllPortsNoAdapters) { |
EXPECT_TRUE(candidate_allocation_done_); |
} |
+// Test that when enumeration is disabled, we should not have any port when |
pthatcher1
2015/09/30 05:32:10
any port => any ports
guoweis_webrtc
2015/09/30 16:29:28
Done.
|
+// candidate_filter() is set to CF_RELAY and no relay is specified. |
+TEST_F(PortAllocatorTest, |
+ TestDisableAdapterEnumerationWithoutNatRelayTransportOnly) { |
+ AddInterfaceAsDefaultRoute(kClientAddr); |
+ ResetWithStunServerNoNat(kStunAddr); |
+ allocator().set_candidate_filter(cricket::CF_RELAY); |
+ // Expect to see no ports. |
+ CheckDisableAdapterEnumeration(0U, rtc::IPAddress(), rtc::IPAddress(), |
+ rtc::IPAddress(), rtc::IPAddress()); |
+} |
+ |
// Test that we should only get STUN and TURN candidates when adapter |
// enumeration is disabled. |
TEST_F(PortAllocatorTest, TestDisableAdapterEnumerationBehindNat) { |