8150535: [TEST_BUG] fix @library for test/java/awt/TrayIcon/MouseMovedTest/MouseMovedTest.java
8151033: [TEST_BUG] typo in java/awt/MouseInfo/PointerInfoCrashTest.java: no sun.awt.peer
8151037: [TEST_BUG] javax/swing/Action/8133039/bug8133039.java requires @modules
8152301: [TESTBUG] Compilation errors in client lib test files
Reviewed-by: serb, alexsch
--- a/jdk/test/java/awt/Mixing/AWT_Mixing/ViewportOverlapping.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/Mixing/AWT_Mixing/ViewportOverlapping.java Fri Mar 25 12:31:16 2016 +0300
@@ -50,9 +50,10 @@
@bug 6778882
@summary Viewport overlapping test for each AWT component
@author sergey.grinev@oracle.com: area=awt.mixing
-@library ../../regtesthelpers
+@library /java/awt/patchlib ../../regtesthelpers
@modules java.desktop/sun.awt
java.desktop/java.awt.peer
+@build java.desktop/java.awt.Helper
@build Util
@run main ViewportOverlapping
*/
--- a/jdk/test/java/awt/MouseInfo/PointerInfoCrashTest.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/MouseInfo/PointerInfoCrashTest.java Fri Mar 25 12:31:16 2016 +0300
@@ -32,7 +32,7 @@
* @test
* @bug 8143316
* @modules java.desktop/java.awt.peer
- * java.desktop/sun.awt.peer
+ * java.desktop/sun.awt
* @summary Crash Trend in 1.9.0-ea-b93 (sun.awt.DefaultMouseInfoPeer.fillPointWithCoords)
*/
public class PointerInfoCrashTest {
--- a/jdk/test/java/awt/Toolkit/Headless/WrappedToolkitTest/WrappedToolkitTest.sh Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/Toolkit/Headless/WrappedToolkitTest/WrappedToolkitTest.sh Fri Mar 25 12:31:16 2016 +0300
@@ -105,17 +105,6 @@
fi
echo "JDK under test is: $TESTJAVA"
-##Deal with .class files:
-#if [ -n "${STANDALONE}" ] ; then
-# # then compile all .java files (if there are any) into .class files
-# if [ -a *.java ]; then
-# ${TESTJAVA}/bin/javac$ ./*.java ;
-# fi
-# # else in harness so copy all the class files from where jtreg put them
-# # over to the scratch directory this test is running in.
-# else cp ${TESTCLASSES}/*.class . ;
-#fi
-#
#if in test harness, then copy the entire directory that the test is in over
# to the scratch directory. This catches any support files needed by the test.
if [ -z "${STANDALONE}" ] ;
--- a/jdk/test/java/awt/TrayIcon/MouseMovedTest/MouseMovedTest.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/TrayIcon/MouseMovedTest/MouseMovedTest.java Fri Mar 25 12:31:16 2016 +0300
@@ -30,7 +30,7 @@
* @bug 7153700
* @summary Check for mouseMoved event for java.awt.TrayIcon
* @author Dmitriy Ermashov (dmitriy.ermashov@oracle.com)
- * @library ../../../../lib/testlibrary
+ * @library ../../../../lib/testlibrary ../
* @build ExtendedRobot SystemTrayIconHelper
* @run main MouseMovedTest
*/
--- a/jdk/test/java/awt/xembed/server/RunTestXEmbed.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/xembed/server/RunTestXEmbed.java Fri Mar 25 12:31:16 2016 +0300
@@ -28,8 +28,8 @@
* @author Denis Mikhalkin: area=awt.xembed
* @requires (!(os.family=="mac") & !(os.family=="windows"))
* @library /lib/testlibrary
+ * @modules java.desktop/sun.awt
* @build jdk.testlibrary.Platform
- * @modules java.desktop/sun.awt
* @compile JavaClient.java TesterClient.java TestXEmbedServer.java
* @run main/timeout=6000 RunTestXEmbed
*/
@@ -39,6 +39,7 @@
import java.util.logging.*;
import java.util.*;
import java.io.*;
+import jdk.testlibrary.Platform;
public class RunTestXEmbed extends TestXEmbedServer {
private static final Logger log = Logger.getLogger("test.xembed");
@@ -72,7 +73,7 @@
}
}
Process proc = Runtime.getRuntime().exec(java_home +
- "/bin/java -Dawt.toolkit=sun.awt.X11.XToolkit TesterClient "
+ "/bin/java -XaddExports:java.desktop/sun.awt.X11=ALL-UNNAMED -Dawt.toolkit=sun.awt.X11.XToolkit TesterClient "
+ test.getName() + " " + window + buf,
enva);
System.err.println("Test for " + test.getName() + " has started.");
--- a/jdk/test/java/awt/xembed/server/TestXEmbedServerJava.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/xembed/server/TestXEmbedServerJava.java Fri Mar 25 12:31:16 2016 +0300
@@ -26,6 +26,7 @@
* @bug 4931668
* @summary Tests XEmbed server/client functionality
* @author denis mikhalkin: area=awt.xembed
+ * @requires (!(os.family=="mac") & !(os.family=="windows"))
* @modules java.desktop/sun.awt
* @compile JavaClient.java TesterClient.java TestXEmbedServer.java
* @run main/manual TestXEmbedServerJava
@@ -38,9 +39,6 @@
public class TestXEmbedServerJava extends TestXEmbedServer {
public static void main(String[] args) {
- if (System.getProperty("os.name").toLowerCase().startsWith("win")) {
- return;
- }
// Enabled XEmbed
System.setProperty("sun.awt.xembedserver", "true");
@@ -78,7 +76,7 @@
public Process startClient(Rectangle[] bounds, long window) {
try {
String java_home = System.getProperty("java.home");
- return Runtime.getRuntime().exec(java_home + "/bin/java JavaClient " + window);
+ return Runtime.getRuntime().exec(java_home + "/bin/java -XaddExports:java.desktop/sun.awt.X11=ALL-UNNAMED JavaClient " + window);
} catch (IOException ex1) {
ex1.printStackTrace();
}
--- a/jdk/test/java/awt/xembed/server/TesterClient.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/java/awt/xembed/server/TesterClient.java Fri Mar 25 12:31:16 2016 +0300
@@ -32,7 +32,6 @@
public static void main(String[] args) throws Throwable {
// First parameter is the name of the test, second is the window, the rest are rectangles
Class cl = Class.forName("sun.awt.X11.XEmbedServerTester");
- cl.getModule().addExports("sun.awt.X11",TesterClient.class.getModule());
test = cl.getMethod(args[0], new Class[0]);
long window = Long.parseLong(args[1]);
--- a/jdk/test/javax/swing/Action/8133039/bug8133039.java Fri Mar 25 11:29:32 2016 +0300
+++ b/jdk/test/javax/swing/Action/8133039/bug8133039.java Fri Mar 25 12:31:16 2016 +0300
@@ -37,6 +37,7 @@
* @test
* @bug 8133039
* @summary Provide public API to sun.swing.UIAction#isEnabled(Object)
+ * @modules java.desktop/sun.swing
* @author Alexander Scherbatiy
*/
public class bug8133039 {