changeset 14260:dd6af52fc8aa

8154543: NetworkInterfaceStreamTest.java fails intermittently after JDK-8146758 Reviewed-by: chegar Contributed-by: Felix Yang <felix.yang@oracle.com>
author xiaofeya
date Wed, 20 Apr 2016 00:35:02 -0700
parents 5976c4eee3e4
children 5f8d20f427b9
files test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java	Tue Apr 19 18:09:58 2016 -0700
+++ b/test/java/net/NetworkInterface/NetworkInterfaceStreamTest.java	Wed Apr 20 00:35:02 2016 -0700
@@ -51,7 +51,8 @@
     public void testNetworkInterfaces() throws SocketException {
         Supplier<Stream<NetworkInterface>> ss = () -> {
             try {
-                return allNetworkInterfaces();
+                return NetworkInterface.networkInterfaces()
+                        .filter(ni -> isIncluded(ni));
             }
             catch (SocketException e) {
                 throw new RuntimeException(e);