Index: content/child/blink_platform_impl_unittest.cc |
diff --git a/content/child/blink_platform_impl_unittest.cc b/content/child/blink_platform_impl_unittest.cc |
index 7217227832d16a4c416211aa7d76980e27e7df73..9db151c4b614a6884915ad83791b973c858fcc83 100644 |
--- a/content/child/blink_platform_impl_unittest.cc |
+++ b/content/child/blink_platform_impl_unittest.cc |
@@ -120,4 +120,16 @@ TEST(BlinkPlatformTest, IsReservedIPAddress) { |
} |
} |
+TEST(BlinkPlatformTest, portAllowed) { |
+ TestBlinkPlatformImpl platform_impl; |
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("example.com"))); |
eroman
2015/04/14 16:38:15
What does this parse as? Please specify a protocol
Paritosh Kumar
2015/04/15 05:43:18
Thanks Done.
|
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("file://example.com"))); |
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("file://example.com:87"))); |
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("ftp://example.com:21"))); |
+ EXPECT_FALSE(platform_impl.portAllowed(GURL("ftp://example.com:87"))); |
+ EXPECT_FALSE(platform_impl.portAllowed(GURL("ws://example.com:21"))); |
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("http://example.com:80"))); |
+ EXPECT_TRUE(platform_impl.portAllowed(GURL("http://example.com:8889"))); |
+} |
+ |
} // namespace content |