dubbo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] zonghaishang commented on a change in pull request #2079: [Dubbo-2064] Ipv6 support
Date Wed, 01 Aug 2018 02:55:07 GMT
zonghaishang commented on a change in pull request #2079: [Dubbo-2064] Ipv6 support
URL: https://github.com/apache/incubator-dubbo/pull/2079#discussion_r206742281
 
 

 ##########
 File path: dubbo-common/src/test/java/org/apache/dubbo/common/utils/NetUtilsTest.java
 ##########
 @@ -180,4 +181,23 @@ public void testToURL() throws Exception {
         String url = NetUtils.toURL("dubbo", "host", 1234, "foo");
         assertThat(url, equalTo("dubbo://host:1234/foo"));
     }
+
+    @Test
+    public void testIsValidV6Address() {
+        System.setProperty("java.net.preferIPv6Addresses", "true");
 
 Review comment:
   ```
   String saved = System.setProperty("java.net.preferIPv6Addresses");
   System.setProperty("java.net.preferIPv6Addresses", "true");
   ...
   System.setProperty("java.net.preferIPv6Addresses", saved);
   ```
   This way is more elegant and will not break subsequent tests.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


Mime
View raw message