8167525: update jdk tests to remove @compile --add-modules workaround
authoramlu
Wed, 08 Mar 2017 15:29:57 +0800
changeset 44108 8de4ce18c36f
parent 44107 a3d145e4f03c
child 44109 df1a27b17bc2
8167525: update jdk tests to remove @compile --add-modules workaround Reviewed-by: mchung
jdk/test/ProblemList.txt
jdk/test/com/sun/jndi/dns/Parser.java
jdk/test/com/sun/jndi/dns/Test6991580.java
jdk/test/com/sun/jndi/rmi/registry/RegistryContext/ContextWithNullProperties.java
jdk/test/java/beans/XMLDecoder/8028054/TestConstructorFinder.java
jdk/test/java/beans/XMLDecoder/8028054/TestMethodFinder.java
jdk/test/java/lang/ClassLoader/platformClassLoader/DefinePlatformClass.java
jdk/test/javax/smartcardio/CommandAPDUTest.java
jdk/test/javax/smartcardio/HistoricalBytes.java
jdk/test/javax/smartcardio/ResponseAPDUTest.java
jdk/test/javax/smartcardio/Serialize.java
jdk/test/javax/smartcardio/TEST.properties
jdk/test/javax/smartcardio/TerminalFactorySpiTest.java
jdk/test/javax/smartcardio/TestCardPermission.java
jdk/test/javax/smartcardio/TestCommandAPDU.java
jdk/test/sun/security/ec/TestEC.java
jdk/test/sun/security/mscapi/IsSunMSCAPIAvailable.java
jdk/test/sun/security/pkcs11/ec/TestCurves.java
jdk/test/sun/security/provider/PolicyFile/Modules.java
--- a/jdk/test/ProblemList.txt	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/ProblemList.txt	Wed Mar 08 15:29:57 2017 +0800
@@ -186,8 +186,6 @@
 java/nio/file/WatchService/MayFlies.java                        7158947 solaris-all Solaris 11
 java/nio/file/WatchService/LotsOfEvents.java                    7158947 solaris-all Solaris 11
 
-sun/nio/cs/OLD/TestIBMDB.java                                   8167525 generic-all
-
 ############################################################################
 
 # jdk_rmi
--- a/jdk/test/com/sun/jndi/dns/Parser.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/com/sun/jndi/dns/Parser.java	Wed Mar 08 15:29:57 2017 +0800
@@ -26,9 +26,6 @@
  * @bug 8035105
  * @summary DNS resource record parsing
  * @modules jdk.naming.dns/com.sun.jndi.dns:+open
- *
- * @compile --add-modules jdk.naming.dns Parser.java
- * @run main Parser
  */
 
 import com.sun.jndi.dns.ResourceRecord;
--- a/jdk/test/com/sun/jndi/dns/Test6991580.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/com/sun/jndi/dns/Test6991580.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,6 +1,6 @@
 
 /*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -37,7 +37,6 @@
  * @summary IPv6 Nameservers in resolv.conf throws NumberFormatException
  * @modules java.desktop
  *          jdk.naming.dns/com.sun.jndi.dns
- * @compile --add-modules jdk.naming.dns IPv6NameserverPlatformParsingTest.java
  * @run main/manual Test6991580
  */
 
--- a/jdk/test/com/sun/jndi/rmi/registry/RegistryContext/ContextWithNullProperties.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/com/sun/jndi/rmi/registry/RegistryContext/ContextWithNullProperties.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -29,7 +29,6 @@
  *     java.rmi/sun.rmi.server java.rmi/sun.rmi.transport java.rmi/sun.rmi.transport.tcp
  * @library ../../../../../../java/rmi/testlibrary
  * @build TestLibrary
- * @compile --add-modules jdk.naming.rmi ContextWithNullProperties.java
  * @run main/othervm ContextWithNullProperties
  */
 
--- a/jdk/test/java/beans/XMLDecoder/8028054/TestConstructorFinder.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/java/beans/XMLDecoder/8028054/TestConstructorFinder.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -39,7 +39,7 @@
  *          java.corba
  *          java.xml.bind
  * @compile -XDignore.symbol.file TestConstructorFinder.java
- * @run main/othervm --add-modules=java.activation,java.transaction,java.corba,java.xml.bind TestConstructorFinder
+ * @run main TestConstructorFinder
  */
 
 public class TestConstructorFinder {
--- a/jdk/test/java/beans/XMLDecoder/8028054/TestMethodFinder.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/java/beans/XMLDecoder/8028054/TestMethodFinder.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2013, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -39,7 +39,7 @@
  *          java.corba
  *          java.xml.bind
  * @compile -XDignore.symbol.file TestMethodFinder.java
- * @run main/othervm --add-modules=java.activation,java.transaction,java.corba,java.xml.bind TestMethodFinder
+ * @run main TestMethodFinder
  */
 
 public class TestMethodFinder {
--- a/jdk/test/java/lang/ClassLoader/platformClassLoader/DefinePlatformClass.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/java/lang/ClassLoader/platformClassLoader/DefinePlatformClass.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,6 @@
  * @summary Test java.* class defined by the platform class loader
  * @modules jdk.zipfs/java.fake
  * @build   jdk.zipfs/java.fake.Fake
- * @compile --add-modules jdk.zipfs DefinePlatformClass.java
  * @run main DefinePlatformClass
  */
 
--- a/jdk/test/javax/smartcardio/CommandAPDUTest.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/CommandAPDUTest.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,7 @@
  * @bug 8049021
  * @summary Test different constructors for CommandAPDU and check CLA,INS,NC,NE,
  * P1,and P2
- * @compile --add-modules=java.smartcardio CommandAPDUTest.java
- * @run testng/othervm --add-modules=java.smartcardio CommandAPDUTest
+ * @run testng CommandAPDUTest
  */
 import java.nio.ByteBuffer;
 import javax.smartcardio.CommandAPDU;
--- a/jdk/test/javax/smartcardio/HistoricalBytes.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/HistoricalBytes.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,6 @@
  * @bug 6445367
  * @summary Verify that ATR.getHistoricalBytes() works
  * @author Andreas Sterbenz
- * @compile --add-modules=java.smartcardio HistoricalBytes.java
- * @run main/othervm --add-modules=java.smartcardio HistoricalBytes
  */
 
 import java.util.Arrays;
--- a/jdk/test/javax/smartcardio/ResponseAPDUTest.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/ResponseAPDUTest.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -25,8 +25,7 @@
  * @test
  * @bug 8049021
  * @summary Construct ResponseAPDU from byte array and check NR< SW, SW1 and SW2
- * @compile --add-modules=java.smartcardio ResponseAPDUTest.java
- * @run testng/othervm --add-modules=java.smartcardio ResponseAPDUTest
+ * @run testng ResponseAPDUTest
  */
 import javax.smartcardio.ResponseAPDU;
 import static org.testng.Assert.*;
--- a/jdk/test/javax/smartcardio/Serialize.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/Serialize.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2006, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,6 @@
  * @bug 6445367
  * @summary make sure serialization works
  * @author Andreas Sterbenz
- * @compile --add-modules=java.smartcardio Serialize.java
- * @run main/othervm --add-modules=java.smartcardio Serialize
  */
 
 import java.io.*;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/jdk/test/javax/smartcardio/TEST.properties	Wed Mar 08 15:29:57 2017 +0800
@@ -0,0 +1,1 @@
+modules = java.smartcardio
--- a/jdk/test/javax/smartcardio/TerminalFactorySpiTest.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/TerminalFactorySpiTest.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2007, 2014, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2007, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -25,8 +25,7 @@
  * @test
  * @bug 8049021
  * @summary Test if we can write new provider for smart card
- * @compile --add-modules=java.smartcardio TerminalFactorySpiTest.java
- * @run main/othervm/java.security.policy=policy --add-modules=java.smartcardio TerminalFactorySpiTest
+ * @run main/othervm/java.security.policy=policy TerminalFactorySpiTest
  */
 import java.security.Provider;
 import java.security.Security;
--- a/jdk/test/javax/smartcardio/TestCardPermission.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/TestCardPermission.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,8 +26,6 @@
  * @bug 6293767 6469513
  * @summary Test for the CardPermission class
  * @author Andreas Sterbenz
- * @compile --add-modules=java.smartcardio TestCardPermission.java
- * @run main/othervm --add-modules=java.smartcardio TestCardPermission
  */
 
 import javax.smartcardio.*;
--- a/jdk/test/javax/smartcardio/TestCommandAPDU.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/javax/smartcardio/TestCommandAPDU.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -27,8 +27,6 @@
  * @summary Test for the CommandAPDU class
  * @author Andreas Sterbenz
  * @key randomness
- * @compile --add-modules=java.smartcardio TestCommandAPDU.java
- * @run main/othervm --add-modules=java.smartcardio TestCommandAPDU
  */
 
 import java.util.*;
--- a/jdk/test/sun/security/ec/TestEC.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/sun/security/ec/TestEC.java	Wed Mar 08 15:29:57 2017 +0800
@@ -35,7 +35,6 @@
  * @library ../pkcs11/sslecc
  * @library ../../../java/security/testlibrary
  * @modules jdk.crypto.cryptoki/sun.security.pkcs11.wrapper
- * @compile --add-modules jdk.crypto.cryptoki TestEC.java
  * @run main/othervm -Djdk.tls.namedGroups="secp256r1,sect193r1" TestEC
  * @run main/othervm/java.security.policy=TestEC.policy -Djdk.tls.namedGroups="secp256r1,sect193r1" TestEC
  */
--- a/jdk/test/sun/security/mscapi/IsSunMSCAPIAvailable.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/sun/security/mscapi/IsSunMSCAPIAvailable.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -26,7 +26,6 @@
  * @bug 6318171 6931562
  * @requires os.family == "windows"
  * @modules jdk.crypto.mscapi/sun.security.mscapi
- * @compile --add-modules jdk.crypto.mscapi IsSunMSCAPIAvailable.java
  * @run main/othervm IsSunMSCAPIAvailable
  */
 
--- a/jdk/test/sun/security/pkcs11/ec/TestCurves.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/sun/security/pkcs11/ec/TestCurves.java	Wed Mar 08 15:29:57 2017 +0800
@@ -28,7 +28,6 @@
  * @author Andreas Sterbenz
  * @library ..
  * @modules jdk.crypto.cryptoki/sun.security.pkcs11.wrapper
- * @compile --add-modules jdk.crypto.cryptoki TestCurves.java
  * @run main/othervm TestCurves
  * @run main/othervm TestCurves sm
  * @key randomness
--- a/jdk/test/sun/security/provider/PolicyFile/Modules.java	Tue Mar 07 23:01:51 2017 -0800
+++ b/jdk/test/sun/security/provider/PolicyFile/Modules.java	Wed Mar 08 15:29:57 2017 +0800
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
@@ -39,7 +39,6 @@
  *          jdk.net
  *          jdk.security.auth
  *          jdk.security.jgss
- * @compile --add-modules=java.xml.ws,java.smartcardio Modules.java
  * @run main/othervm/java.security.policy==modules.policy Modules
  */