aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Azores <[email protected]>2013-11-27 16:37:38 -0500
committerAndrew Azores <[email protected]>2013-11-27 16:37:38 -0500
commitde9b5d773fb4adec13673ca26cb61b534e6c5012 (patch)
treea5db29703e13c5bf905b01d79c64aee4854ed56a
parent4e54b331710269c584f8c328fbb395789b4a5502 (diff)
JNLPClassLoaderDeadlock reproducer made more reliable
-rw-r--r--ChangeLog10
-rw-r--r--tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java1
-rw-r--r--tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java1
-rw-r--r--tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java7
4 files changed, 15 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 3f7b1bb..d29b310 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2013-11-27 Andrew Azores <[email protected]>
+
+ Made JNLPClassLoaderDeadlock reproducer more reliable
+ * tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java:
+ Removed "AutoOkClosingListener" magic string
+ * tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java:
+ same
+ * tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java:
+ Changed AutoOkClosingListener to RulesFolowingClosingListener
+
2013-11-26 Jiri Vanek <[email protected]>
Reverted "fix to ManifestedJar1Test cases", better manifestedjar tests,
diff --git a/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java b/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java
index 616e5d3..40e7ab9 100644
--- a/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java
+++ b/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_1.java
@@ -15,7 +15,6 @@ public class JNLPClassLoaderDeadlock_1 extends Applet {
setBackground(Color.white);
add(tf);
System.out.println("JNLPClassLoaderDeadlock_1 applet finished");
- System.out.println("*** APPLET FINISHED ***");
}
public static void main(String[] args) {
diff --git a/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java b/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java
index 6def405..a3c0788 100644
--- a/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java
+++ b/tests/reproducers/custom/JNLPClassLoaderDeadlock/srcs/JNLPClassLoaderDeadlock_2.java
@@ -78,6 +78,5 @@ public class JNLPClassLoaderDeadlock_2 extends Applet implements Runnable {
}
}
System.out.println("JNLPClassLoaderDeadlock_2 applet finished");
- System.out.println("*** APPLET FINISHED ***");
}
}
diff --git a/tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java b/tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java
index 84b93d8..bc87e9d 100644
--- a/tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java
+++ b/tests/reproducers/custom/JNLPClassLoaderDeadlock/testcases/JNLPClassLoaderDeadlockTest.java
@@ -43,7 +43,7 @@ import net.sourceforge.jnlp.annotations.NeedsDisplay;
import net.sourceforge.jnlp.annotations.TestInBrowsers;
import net.sourceforge.jnlp.browsertesting.BrowserTest;
import net.sourceforge.jnlp.browsertesting.Browsers;
-import net.sourceforge.jnlp.closinglisteners.AutoOkClosingListener;
+import net.sourceforge.jnlp.closinglisteners.RulesFolowingClosingListener;
import static org.junit.Assert.assertTrue;
import org.junit.Test;
@@ -55,7 +55,10 @@ public class JNLPClassLoaderDeadlockTest extends BrowserTest {
@TestInBrowsers(testIn={Browsers.one})
@Bug(id="RH976833")
public void testClassLoaderDeadlock() throws Exception {
- ProcessResult pr = server.executeBrowser("JNLPClassLoaderDeadlock.html", AutoClose.CLOSE_ON_CORRECT_END);
+ RulesFolowingClosingListener listener = new RulesFolowingClosingListener();
+ listener.addContainsRule("JNLPClassLoaderDeadlock_1 applet finished");
+ listener.addContainsRule("JNLPClassLoaderDeadlock_2 applet finished");
+ ProcessResult pr = server.executeBrowser("JNLPClassLoaderDeadlock.html", listener, null);
assertTrue("First applet should have initialized",
pr.stdout.contains("JNLPClassLoaderDeadlock_1 applet initialized"));
assertTrue("Second applet should have initialized",