Changeset 429 for trunk/icedtea-web/tests/reproducers/signed
- Timestamp:
- Sep 24, 2014, 9:34:21 PM (11 years ago)
- Location:
- trunk/icedtea-web/tests/reproducers/signed
- Files:
-
- 1 deleted
- 22 edited
- 18 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/icedtea-web/tests/reproducers/signed/AppletTestSigned/resources/AppletTestSigned.html
r418 r429 38 38 <html><head></head><body bgcolor="red"> 39 39 <p> 40 <applet code="AppletTestSigned.class" archive=" XslowXAppletTestSigned.jar" codebase="." width="100" height="100">40 <applet code="AppletTestSigned.class" archive="AppletTestSigned.jar" codebase="." width="100" height="100"> 41 41 <param name="key1" value="value1"> 42 42 <param name="key2" value="#value2"> -
trunk/icedtea-web/tests/reproducers/signed/AppletTestSigned/srcs/AppletTestSigned.java
r418 r429 49 49 Thread.sleep(n); 50 50 System.out.println("AppletTestSigned killing himself after " + n + " ms of life"); 51 System.out.println("*** APPLET FINISHED ***"); 51 52 System.exit(0); 52 53 } catch (Exception ex) { -
trunk/icedtea-web/tests/reproducers/signed/AppletTestSigned/testcases/AppletTestSignedTests.java
r418 r429 44 44 import net.sourceforge.jnlp.browsertesting.Browsers; 45 45 import net.sourceforge.jnlp.annotations.TestInBrowsers; 46 import net.sourceforge.jnlp.closinglisteners.Rule; 47 import net.sourceforge.jnlp.closinglisteners.RulesFolowingClosingListener; 48 import static net.sourceforge.jnlp.closinglisteners.RulesFolowingClosingListener.*; 46 49 import org.junit.Assert; 47 50 … … 51 54 52 55 private final List<String> l = Collections.unmodifiableList(Arrays.asList(new String[]{"-Xtrustall"})); 56 private static final String s0 = "AppletTestSigned was started"; 57 private static final String s1 = "value1"; 58 private static final String s2 = "value2"; 59 private static final String s3 = "AppletTestSigned was initialised"; 60 private static final String s7 = "AppletTestSigned killing himself after 2000 ms of life"; 61 private static final ContainsRule startedRule = new ContainsRule(s0); 62 private static final ContainsRule variable1Rule = new ContainsRule(s1); 63 private static final ContainsRule variable2Rule = new ContainsRule(s2); 64 private static final ContainsRule initialisedRule = new ContainsRule(s3); 65 private static final ContainsRule killedRule = new ContainsRule(s7); 66 private static final RulesFolowingClosingListener okListener=new RulesFolowingClosingListener(startedRule, variable1Rule, variable2Rule, initialisedRule, killedRule); 53 67 54 @Test68 // @Test 55 69 public void AppletTestSignedTest() throws Exception { 56 70 ProcessResult pr = server.executeJavawsHeadless(l, "/AppletTestSigned.jnlp"); … … 61 75 62 76 private void evaluateSignedApplet(ProcessResult pr, boolean javawsApplet) { 63 String s3 = "AppletTestSigned was initialised"; 64 Assert.assertTrue("AppletTestSigned stdout should contain " + s3 + " but didn't", pr.stdout.contains(s3)); 65 String s0 = "AppletTestSigned was started"; 66 Assert.assertTrue("AppletTestSigned stdout should contain " + s0 + " but didn't", pr.stdout.contains(s0)); 67 String s1 = "value1"; 68 Assert.assertTrue("AppletTestSigned stdout should contain " + s1 + " but didn't", pr.stdout.contains(s1)); 69 String s2 = "value2"; 70 Assert.assertTrue("AppletTestSigned stdout should contain " + s2 + " but didn't", pr.stdout.contains(s2)); 71 String ss = "xception"; 72 Assert.assertFalse("AppletTestSigned stderr should not contain " + ss + " but did", pr.stderr.contains(ss)); 73 String s7 = "AppletTestSigned killing himself after 2000 ms of life"; 74 Assert.assertTrue("AppletTestSigned stdout should contain " + s7 + " but didn't", pr.stdout.contains(s7)); 77 Assert.assertTrue("AppletTestSigned stdout " + initialisedRule.toPassingString() + " but didn't", initialisedRule.evaluate(pr.stdout)); 78 Assert.assertTrue("AppletTestSigned stdout " + startedRule.toPassingString() + " but didn't", startedRule.evaluate(pr.stdout)); 79 Assert.assertTrue("AppletTestSigned stdout " + variable1Rule.toPassingString() + " but didn't", variable1Rule.evaluate(pr.stdout)); 80 Assert.assertTrue("AppletTestSigned stdout " + variable2Rule.toPassingString() + " but didn't", variable2Rule.evaluate(pr.stdout)); 81 Assert.assertTrue("AppletTestSigned stdout " + killedRule.toPassingString() + " but didn't", killedRule.evaluate(pr.stdout)); 75 82 if (!javawsApplet) { 76 83 /*this is working correctly in most browser, but not in all. temporarily disabling … … 85 92 @Test 86 93 @TestInBrowsers(testIn = {Browsers.all}) 87 public void AppletTestSignedFirefoxTest () throws Exception {94 public void AppletTestSignedFirefoxTestXslowX() throws Exception { 88 95 ServerAccess.PROCESS_TIMEOUT = 30 * 1000; 89 96 try { 90 ProcessResult pr = server.executeBrowser("/AppletTestSigned .html");97 ProcessResult pr = server.executeBrowser("/AppletTestSigned2.html", okListener, null); 91 98 evaluateSignedApplet(pr, false); 92 Assert.assertTrue(pr.wasTerminated);99 //Assert.assertTrue(pr.wasTerminated); 93 100 //Assert.assertEquals((Integer) 0, pr.returnValue); due to destroy is null 94 101 } finally { … … 96 103 } 97 104 } 105 106 @Test 107 @TestInBrowsers(testIn = {Browsers.all}) 108 public void AppletTestSignedFirefoxTest() throws Exception { 109 ProcessResult pr = server.executeBrowser("/AppletTestSigned.html", ServerAccess.AutoClose.CLOSE_ON_CORRECT_END); 110 evaluateSignedApplet(pr, false); 111 //Assert.assertTrue(pr.wasTerminated); 112 //Assert.assertEquals((Integer) 0, pr.returnValue); due to destroy is null 113 } 98 114 } -
trunk/icedtea-web/tests/reproducers/signed/CacheReproducer/testcases/CacheReproducerTest.java
r418 r429 45 45 import java.util.Arrays; 46 46 import java.util.List; 47 import java.util.PropertyResourceBundle; 47 48 import java.util.regex.Matcher; 48 49 import java.util.regex.Pattern; 49 50 import net.sourceforge.jnlp.ServerAccess; 50 import net.sourceforge.jnlp. ServerAccess.ProcessResult;51 import net.sourceforge.jnlp.ProcessResult; 51 52 import net.sourceforge.jnlp.annotations.KnownToFail; 53 import net.sourceforge.jnlp.config.Defaults; 54 import net.sourceforge.jnlp.tools.MessageProperties; 52 55 import org.junit.AfterClass; 53 56 import org.junit.Assert; … … 61 64 private static final List<String> trustedVerboses = Arrays.asList(new String[]{"-Xtrustall", ServerAccess.HEADLES_OPTION,"-verbose"}); 62 65 private static final List<String> verbosed = Arrays.asList(new String[]{"-verbose", ServerAccess.HEADLES_OPTION}); 63 private static final String home = System.getProperty("user.home"); 64 private static final String name = System.getProperty("user.name"); 65 private static final String tmp = System.getProperty("java.io.tmpdir"); 66 private static final File icedteaDir = new File(home + "/" + ".icedtea"); 67 private static final File icedteaCache = new File(icedteaDir, "cache"); 68 private static final File icedteaCacheFile = new File(icedteaCache, "recently_used"); 69 private static final File netxLock = new File(tmp + "/" + name + "/netx/locks/netx_running"); 66 70 67 private static final String lre = "LruCacheException"; 71 68 private static final String ioobe = "IndexOutOfBoundsException"; … … 74 71 private static final String corruptString = "156dsf1562kd5"; 75 72 76 String testS = "#netx file\n" 77 + "#Mon Dec 12 16:20:46 CET 2011\n" 78 + "1323703236508,0=/home/xp13/.icedtea/cache/0/http/localhost/ReadPropertiesBySignedHack.jnlp\n" 79 + "1323703243086,2=/home/xp14/.icedtea/cache/2/http/localhost/ReadProperties.jar\n" 80 + "1323703243082,1=/home/xp15/.icedtea/cache/1/http/localhost/ReadPropertiesBySignedHack.jar"; 73 private static final File icedteaCache = new File(Defaults.USER_CACHE_HOME, "cache"); 74 private static final File icedteaCacheFile = new File(icedteaCache, "recently_used"); 75 private static final File netxLock = new File(System.getProperty("java.io.tmpdir"), 76 System.getProperty("user.name") + File.separator + 77 "netx" + File.separator + 78 "locks" + File.separator + 79 "netx_running"); 80 81 String testS = "#netx file\n" 82 + "#Mon Dec 12 16:20:46 CET 2011\n" 83 + "1323703236508,0=/home/xp13/.icedtea/cache/0/http/localhost/ReadPropertiesBySignedHack.jnlp\n" 84 + "1323703243086,2=/home/xp14/.icedtea/cache/2/http/localhost/ReadProperties.jar\n" 85 + "1323703243082,1=/home/xp15/.icedtea/cache/1/http/localhost/ReadPropertiesBySignedHack.jar"; 81 86 82 87 @Test … … 94 99 } 95 100 96 private class ParallelSimpleTestRunner extends Thread { 97 public boolean b=false; 98 @Override 99 public void run() { 100 try { 101 102 ServerAccess.ProcessResult pr = runSimpleTest1(); 103 evaluateSimpleTest1OkCache(pr); 104 b=true; 105 } catch (Exception ex) { 106 throw new RuntimeException(ex); 107 } 108 } 109 }; 101 private class ParallelSimpleTestRunner extends Thread { 102 public boolean b=false; 103 @Override 104 public void run() { 105 try { 106 ProcessResult pr = runSimpleTest1(); 107 evaluateSimpleTest1OkCache(pr); 108 b=true; 109 } catch (Exception ex) { 110 throw new RuntimeException(ex); 111 } 112 } 113 } 110 114 111 115 @Test … … 261 265 public void run() { 262 266 try { 263 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(verbosed, "/deadlocktest.jnlp");267 ProcessResult pr = server.executeJavawsHeadless(verbosed, "/deadlocktest.jnlp"); 264 268 } catch (Exception ex) { 265 269 throw new RuntimeException(ex); … … 270 274 Thread.sleep(1000); 271 275 pr = tryToClearcache(); 272 String q = "Can not clear cache at this time"; 273 Assert.assertTrue("Stderr should contain " + q + ", but did not.", pr.stderr.contains(q));274 assertCacheIsNotEmpty();275 }276 277 276 277 String cacheClearError = MessageProperties.getMessage("CCannotClearCache"); 278 Assert.assertTrue("Stderr should contain " + cacheClearError + ", but did not.", pr.stderr.contains(cacheClearError)); 279 assertCacheIsNotEmpty(); 280 } 281 278 282 //next four tests are designed to ensure, that corrupted cache will not break already loaded cached files 279 283 public static final String CR1 = "CacheReproducer1"; … … 338 342 if (netxLock.isFile()) { 339 343 boolean b = netxLock.delete(); 340 junit.framework.Assert.assertTrue(b);344 Assert.assertTrue(b); 341 345 } 342 346 … … 378 382 } 379 383 String sb = breakOne(s, 0); 380 junit.framework.Assert.assertEquals(s, sb);384 Assert.assertEquals(s, sb); 381 385 for (int x = 1; x <= 3; x++) { 382 386 String[] sx = breakOne(s, x).split("\n"); … … 427 431 428 432 private static String breakPaths(String s) { 429 return s.replaceAll( home+".*", "/ho");433 return s.replaceAll(System.getProperty("user.home") + ".*", "/ho"); 430 434 } 431 435 … … 448 452 } 449 453 450 private static ServerAccess.ProcessResult runSimpleTest1() throws Exception {454 private static ProcessResult runSimpleTest1() throws Exception { 451 455 return runSimpleTest1(verbosed, "simpletest1"); 452 456 } 453 457 454 private static ServerAccess.ProcessResult runSimpleTest1(List<String> args, String s) throws Exception {455 ServerAccess.ProcessResult pr2 = server.executeJavawsHeadless(args, "/" + s + ".jnlp");458 private static ProcessResult runSimpleTest1(List<String> args, String s) throws Exception { 459 ProcessResult pr2 = server.executeJavawsHeadless(args, "/" + s + ".jnlp"); 456 460 return pr2; 457 461 } 458 462 459 private static ServerAccess.ProcessResult runSimpleTest1Signed() throws Exception {463 private static ProcessResult runSimpleTest1Signed() throws Exception { 460 464 return runSimpleTestSigned("SimpletestSigned1"); 461 465 } 462 466 463 private static ServerAccess.ProcessResult runSimpleTestSigned(String id) throws Exception {467 private static ProcessResult runSimpleTestSigned(String id) throws Exception { 464 468 return runSimpleTest1(trustedVerboses, id); 465 469 } 466 470 467 private static void evaluateSimpleTest1OkCache( ServerAccess.ProcessResult pr2) throws Exception {471 private static void evaluateSimpleTest1OkCache(ProcessResult pr2) throws Exception { 468 472 String s = "Good simple javaws exapmle"; 469 473 Assert.assertTrue("test stdout should contain " + s + " but didn't", pr2.stdout.contains(s)); … … 473 477 474 478 private static ProcessResult tryToClearcache() throws Exception { 475 ServerAccess.ProcessResult pr1 = ServerAccess.executeProcess(clear);479 ProcessResult pr1 = ServerAccess.executeProcess(clear); 476 480 return pr1; 477 481 } -
trunk/icedtea-web/tests/reproducers/signed/ClasspathManifestTest/testcases/ClasspathManifestTest.java
r418 r429 39 39 import java.util.List; 40 40 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 42 import net.sourceforge.jnlp.ServerAccess.ProcessResult;43 import net.sourceforge.jnlp.annotations.Bug;44 43 import net.sourceforge.jnlp.annotations.KnownToFail; 45 44 import net.sourceforge.jnlp.annotations.NeedsDisplay; … … 51 50 import org.junit.Test; 52 51 53 @Bug(id = "PR975")54 52 public class ClasspathManifestTest extends BrowserTest { 55 53 … … 79 77 commands.add(ServerAccess.HEADLES_OPTION); 80 78 commands.add("ClasspathManifestApplicationTest.jnlp"); 81 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir());79 ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir()); 82 80 checkAppFails(pr, "ApplicationJNLPLocalTest"); 83 81 } … … 86 84 @Test 87 85 public void AppletJNLPRemoteTest() throws Exception { 88 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/ClasspathManifestAppletTest.jnlp");86 ProcessResult pr = server.executeJavawsHeadless(null, "/ClasspathManifestAppletTest.jnlp"); 89 87 checkAppFails(pr, "AppletJNLPRemoteTest"); 90 88 } … … 98 96 commands.add(ServerAccess.HEADLES_OPTION); 99 97 commands.add("ClasspathManifestAppletTest.jnlp"); 100 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir());98 ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir()); 101 99 checkAppFails(pr, "AppletJNLPRLocalTest"); 102 100 } … … 106 104 @Test 107 105 public void BrowserJNLPHrefRemoteTest() throws Exception { 108 ServerAccess.ProcessResult pr = server.executeBrowser("/ClasspathManifestJNLPHrefTest.html");106 ProcessResult pr = server.executeBrowser("/ClasspathManifestJNLPHrefTest.html"); 109 107 checkAppFails(pr, "BrowserJNLPHrefRemoteTest"); 110 108 } … … 118 116 commands.add(server.getBrowserLocation()); 119 117 commands.add("ClasspathManifestJNLPHrefTest.html"); 120 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir());118 ProcessResult pr = ServerAccess.executeProcess(commands, server.getDir()); 121 119 checkAppFails(pr, "BrowserJNLPHrefLocalTest"); 122 120 } … … 126 124 @Test 127 125 public void BrowserAppletRemoteTest() throws Exception { 128 ServerAccess.ProcessResult pr = server.executeBrowser("/ClasspathManifestAppletTest.html");126 ProcessResult pr = server.executeBrowser("/ClasspathManifestAppletTest.html"); 129 127 Assert.assertTrue("ClasspathManifest.BrowserAppletRemoteTest stdout should contain " + s1 + " but didn't", pr.stdout.contains(s1)); 130 128 // Should be the only one to search manifest for classpath. 131 129 Assert.assertTrue("ClasspathManifest.BrowserAppletRemoteTest stdout should contain " + s2 + " but didn't", pr.stdout.contains(s2)); 132 Assert.assertFalse("ClasspathManifest.BrowserAppletRemoteTest stderr should not contain " + ss + " but did", pr.stderr.contains(ss));133 130 } 134 131 } -
trunk/icedtea-web/tests/reproducers/signed/ExtensionJnlp/testcases/ExtensionJnlpTest.java
r418 r429 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 42 43 import net.sourceforge.jnlp.annotations.Bug; … … 56 57 @Test 57 58 public void checkingForRequiredResources() throws Exception { 58 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJar.jnlp");59 ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJar.jnlp"); 59 60 Assert.assertTrue("Could not locate SignedJarResource class within SignedJarResource jar", pr.stdout.contains(jarOutput)); 60 61 … … 67 68 @Test 68 69 public void usingSignedExtension() throws Exception { 69 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJarExtension.jnlp");70 ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJarExtension.jnlp"); 70 71 Assert.assertTrue("Stdout should contain " + jarOutput + " but did not", pr.stdout.contains(jarOutput)); 71 72 } … … 74 75 @Test 75 76 public void mainJarInExtension() throws Exception { 76 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJnlpJarAndSignedJarExtension.jnlp");77 ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJnlpJarAndSignedJarExtension.jnlp"); 77 78 Assert.assertTrue("Stdout should contain " + jarOutput + " but did not", pr.stdout.contains(jarOutput)); 78 79 } … … 81 82 @Test 82 83 public void checkingSignedJnlpInExtension() throws Exception { 83 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJnlpExtension.jnlp");84 ProcessResult pr = server.executeJavawsHeadless(l, "/UsesSignedJnlpExtension.jnlp"); 84 85 Assert.assertTrue("Stdout should contain " + signedJnlpException + " but did not", pr.stderr.contains(signedJnlpException)); 85 86 } -
trunk/icedtea-web/tests/reproducers/signed/InternalClassloaderWithDownloadedResource/testcases/InternalClassloaderWithDownloadedResourceTest.java
r418 r429 40 40 import java.util.Collections; 41 41 import java.util.List; 42 import net.sourceforge.jnlp.ProcessResult; 42 43 import net.sourceforge.jnlp.ServerAccess; 43 import net.sourceforge.jnlp.ServerAccess.ProcessResult;44 44 import net.sourceforge.jnlp.annotations.Bug; 45 45 import net.sourceforge.jnlp.annotations.NeedsDisplay; … … 79 79 @Bug(id = {"RH816592","PR858"}) 80 80 public void launchInternalClassloaderWithDownloadedResourceAsJnlpApplication() throws Exception { 81 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-new.jnlp");81 ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-new.jnlp"); 82 82 evaluate(pr); 83 83 Assert.assertFalse("should not be terminated but was", pr.wasTerminated); … … 88 88 String ss = "Good simple javaws exapmle"; 89 89 Assert.assertTrue("Stdout should contains " + ss + " but didn't", pr.stdout.contains(ss)); 90 String s = "xception";91 Assert.assertFalse("Stderr should not contains " + s + " but did", pr.stderr.contains(s));92 90 } 93 91 … … 95 93 @Bug(id = {"RH816592","PR858"}) 96 94 public void launchInternalClassloaderWithDownloadedResourceAsJnlpApplet() throws Exception { 97 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-applet-new.jnlp");95 ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-applet-new.jnlp"); 98 96 evaluate(pr); 99 97 Assert.assertFalse("should not be terminated but was", pr.wasTerminated); … … 106 104 @TestInBrowsers(testIn={Browsers.all}) 107 105 public void launchInternalClassloaderWithDownloadedResourceAsHtmlApplet() throws Exception { 108 ServerAccess.ProcessResult pr = server.executeBrowser("/InternalClassloaderWithDownloadedResource-new.html");106 ProcessResult pr = server.executeBrowser("/InternalClassloaderWithDownloadedResource-new.html"); 109 107 evaluate(pr); 110 108 Assert.assertTrue("should be terminated but was not", pr.wasTerminated); … … 114 112 @Bug(id = {"http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2012-May/018737.html"}) 115 113 public void launchInternalClassloaderWithDownloadedResourceAsJnlpApplicationHack() throws Exception { 116 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-hack.jnlp");114 ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-hack.jnlp"); 117 115 evaluate(pr); 118 116 Assert.assertFalse("should not be terminated but was", pr.wasTerminated); … … 123 121 @Bug(id = {"http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2012-May/018737.html"}) 124 122 public void launchInternalClassloaderWithDownloadedResourceAsJnlpAppletHack() throws Exception { 125 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-applet-hack.jnlp");123 ProcessResult pr = server.executeJavawsHeadless(l, "/InternalClassloaderWithDownloadedResource-applet-hack.jnlp"); 126 124 evaluate(pr); 127 125 Assert.assertFalse("should not be terminated but was", pr.wasTerminated); … … 134 132 @TestInBrowsers(testIn={Browsers.all}) 135 133 public void launchInternalClassloaderWithDownloadedResourceAsHtmlAppletHack() throws Exception { 136 ServerAccess.ProcessResult pr = server.executeBrowser("/InternalClassloaderWithDownloadedResource-hack.html");134 ProcessResult pr = server.executeBrowser("/InternalClassloaderWithDownloadedResource-hack.html"); 137 135 evaluate(pr); 138 136 Assert.assertTrue("should be terminated but was not", pr.wasTerminated); -
trunk/icedtea-web/tests/reproducers/signed/MissingJar/testcases/MissingJarTest.java
r418 r429 1 /* MissingJar .java1 /* MissingJarTest.java 2 2 Copyright (C) 2011 Red Hat, Inc. 3 3 … … 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 42 import net.sourceforge.jnlp.ServerAccess.ProcessResult; 43 43 44 import org.junit.Assert; 44 45 45 import org.junit.Test; 46 46 … … 61 61 @Test 62 62 public void MissingJarTest1() throws Exception { 63 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar.jnlp");63 ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar.jnlp"); 64 64 evaluateResult(pr); 65 65 } … … 67 67 @Test 68 68 public void MissingJarTest2() throws Exception { 69 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar2.jnlp");69 ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar2.jnlp"); 70 70 evaluateResult(pr); 71 71 } … … 73 73 @Test 74 74 public void MissingJarTest3() throws Exception { 75 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar3.jnlp");75 ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar3.jnlp"); 76 76 evaluateResult(pr); 77 77 } … … 79 79 @Test 80 80 public void MissingJarTest4() throws Exception { 81 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar4.jnlp");81 ProcessResult pr = server.executeJavawsHeadless(l, "/MissingJar4.jnlp"); 82 82 evaluateResult(pr); 83 83 } -
trunk/icedtea-web/tests/reproducers/signed/ReadPropertiesBySignedHack/testcases/ReadPropertiesBySignedHackTest.java
r418 r429 1 /* ReadProperties SignedTest.java1 /* ReadPropertiesBySignedHackTest.java 2 2 Copyright (C) 2011 Red Hat, Inc. 3 3 … … 36 36 */ 37 37 38 39 38 import java.util.Arrays; 40 39 import java.util.Collections; 41 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 42 42 import net.sourceforge.jnlp.ServerAccess; 43 43 44 import org.junit.Assert; 44 45 import org.junit.Test; … … 53 54 public void ReadPropertiesBySignedHackWithjoutXtrustAll() throws Exception { 54 55 //no request for permissions 55 ServerAccess.ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesBySignedHack.jnlp");56 ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesBySignedHack.jnlp"); 56 57 String s="java.lang.SecurityException: class \"ReadProperties\"'s signer information does not match signer information of other classes in the same package"; 57 58 Assert.assertTrue("Stderr should contains "+s+" but did not",pr.stderr.contains(s)); 58 59 String ss="ClassNotFoundException"; 59 60 Assert.assertFalse("Stderr should not contains "+ss+" but did",pr.stderr.contains(ss)); 60 Assert.assertTrue("stdout lenght should be <2 but was "+pr.stdout.length(),pr.stdout.length()<2); // /home/user or /root or eanything else :(61 61 Assert.assertFalse("should not be terminated but was",pr.wasTerminated); 62 62 Assert.assertEquals((Integer)0, pr.returnValue); -
trunk/icedtea-web/tests/reproducers/signed/ReadPropertiesSigned/testcases/ReadPropertiesSignedTest.java
r418 r429 36 36 */ 37 37 38 39 38 import java.util.Arrays; 40 39 import java.util.Collections; 41 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 42 42 import net.sourceforge.jnlp.ServerAccess; 43 43 44 import org.junit.Assert; 44 45 import org.junit.Test; … … 54 55 public void ReadSignedPropertiesWithoutPermissionsWithXtrustAll() throws Exception { 55 56 //no request for permissions 56 ServerAccess.ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesSigned1.jnlp");57 ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesSigned1.jnlp"); 57 58 Assert.assertTrue("Stderr should match "+accessMatcher+" but did not",pr.stderr.matches(accessMatcher)); 58 59 String ss="ClassNotFoundException"; 59 60 Assert.assertFalse("Stderr should not contains "+ss+" but did",pr.stderr.contains(ss)); 60 Assert.assertTrue("stdout lenght should be <2 but was "+pr.stdout.length(),pr.stdout.length()<2); // /home/user or /root or eanything else :(61 61 Assert.assertFalse("should not be terminated but was",pr.wasTerminated); 62 62 Assert.assertEquals((Integer)0, pr.returnValue); … … 66 66 public void ReadSignedPropertiesWithPermissionsWithXtrustAll() throws Exception { 67 67 //request for allpermissions 68 ServerAccess.ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesSigned2.jnlp");68 ProcessResult pr=server.executeJavawsHeadless(l,"/ReadPropertiesSigned2.jnlp"); 69 69 Assert.assertFalse("Stderr should NOT match "+accessMatcher+" but did",pr.stderr.matches(accessMatcher)); 70 70 String ss="ClassNotFoundException"; 71 71 Assert.assertFalse("Stderr should not contains "+ss+" but did",pr.stderr.contains(ss)); 72 Assert.assertTrue("stdout lenght should be >= but was "+pr.stdout.length(),pr.stdout.length()>=4); // /home/user or /root or eanything else :(73 72 Assert.assertFalse("should not be terminated but was",pr.wasTerminated); 74 73 Assert.assertEquals((Integer)0, pr.returnValue); … … 77 76 @Test 78 77 public void EnsureXtrustallNotAffectingUnsignedBehaviour() throws Exception { 79 ServerAccess.ProcessResult pr=server.executeJavawsHeadless(l,"/ReadProperties1.jnlp");78 ProcessResult pr=server.executeJavawsHeadless(l,"/ReadProperties1.jnlp"); 80 79 Assert.assertTrue("Stderr should match "+accessMatcher+" but did not",pr.stderr.matches(accessMatcher)); 81 80 String ss="ClassNotFoundException"; 82 81 Assert.assertFalse("Stderr should not contains "+ss+" but did",pr.stderr.contains(ss)); 83 Assert.assertFalse("stdout lenght should not be >2 but was "+pr.stdout.length(),pr.stdout.length()>2);84 82 Assert.assertFalse("should not be terminated but was",pr.wasTerminated); 85 83 Assert.assertEquals((Integer)0, pr.returnValue); 86 ServerAccess.ProcessResult pr2=server.executeJavawsHeadless(null,"/ReadProperties1.jnlp");84 ProcessResult pr2=server.executeJavawsHeadless(null,"/ReadProperties1.jnlp"); 87 85 Assert.assertEquals(pr.stderr, pr2.stderr); 88 86 Assert.assertEquals(pr.stdout, pr2.stdout); 89 90 87 } 91 88 } -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/resources/CheckCookieAndGotoClear.html
r418 r429 38 38 39 39 <!-- Uses show-document to go to a page that clears the cookie --> 40 40 41 41 <html><head></head><body bgcolor="red"> 42 42 <p> 43 43 <applet code="CheckingCookies.class" archive="SavingCookies.jar" codebase="." width="100" height="100"> 44 44 45 45 <param name="show-document" value="ClearPersistentCookie.html"> 46 46 47 47 </applet> 48 48 </p> -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/resources/ClearPersistentCookie.html
r418 r429 41 41 42 42 <param name="persistent" value="no"> 43 43 44 44 <param name="cookie" value="TEST=deleted; Expires=Thu, 01 Jan 1970 00:00:01 GMT"> 45 45 -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/resources/SavePersistentCookie.html
r418 r429 41 41 42 42 <param name="persistent" value="yes"> 43 43 44 44 <param name="cookie" value="TEST=persistent"> 45 45 46 46 </applet> 47 47 </p> -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/resources/SavePersistentCookieAndGotoCheck.html
r418 r429 42 42 <param name="show-document" value="CheckCookieAndGotoClear.html"> 43 43 <param name="persistent" value="yes"> 44 44 45 45 <param name="cookie" value="TEST=persistent"> 46 46 -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/resources/SaveSessionCookie.html
r418 r429 41 41 42 42 <param name="persistent" value="no"> 43 43 44 44 <param name="cookie" value="TEST=session"> 45 45 -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/srcs/SavingCookies.java
r418 r429 1 1 /* SavingCookies.java 2 2 Store cookies in the java cookie store, and go to a page that confirms they are there. 3 3 4 4 Copyright (C) 2012 Red Hat, Inc. 5 5 -
trunk/icedtea-web/tests/reproducers/signed/SavingCookies/testcases/SavingCookiesTests.java
r418 r429 51 51 52 52 public class SavingCookiesTests extends BrowserTest { 53 53 54 54 static final String ENTERING_CHECK = "Entered CheckingCookies"; 55 55 static final String CHECKING_COMPLETION = "Finished CheckingCookies"; … … 86 86 }; 87 87 if (url.endsWith(".html")) { 88 pr = server.executeBrowser(url, stdoutListener, stdoutListener);88 pr = server.executeBrowser(url, stdoutListener, null); 89 89 } else if (url.endsWith(".jnlp")) { 90 pr = server.executeJavawsHeadless(TRUSTALL, url, stdoutListener, stdoutListener);90 pr = server.executeJavawsHeadless(TRUSTALL, url, stdoutListener, null, null); 91 91 } 92 92 } catch (Exception ex) { … … 106 106 final String COOKIE_SANITY_CHECK = "Found cookie: TEST="; 107 107 ProcessResult pr = server.executeBrowser("/CheckCookie.html"); 108 108 109 109 Assert.assertFalse("stdout should NOT contain '" + COOKIE_SANITY_CHECK + "' but did.", pr.stdout.contains(COOKIE_SANITY_CHECK)); 110 110 Assert.assertTrue("stdout should contain '" + CHECKING_COMPLETION + "' but did not.", pr.stdout.contains(CHECKING_COMPLETION)); 111 111 } 112 112 113 113 @Test 114 114 @TestInBrowsers(testIn = { Browsers.one }) … … 130 130 Thread.sleep(100); 131 131 } 132 132 133 133 ProcessResult check = server.executeBrowser("/CheckCookie.html"); 134 134 save.join(); 135 135 136 136 Assert.assertTrue("stdout should contain '" + ENTERING_CHECK + "' but did not.", save.pr.stdout.contains(ENTERING_CHECK)); 137 137 //XXX: It is necessary to check save.pr's stdout, because it does not show up in 'check.stdout' for some reason … … 155 155 public void AppletPersistentCookieShowDoc() throws Exception { 156 156 ProcessResult pr = server.executeBrowser("/SavePersistentCookieAndGotoCheck.html"); 157 157 158 158 Assert.assertTrue("stdout should contain '" + ENTERING_CHECK + "' but did not.", pr.stdout.contains(ENTERING_CHECK)); 159 159 Assert.assertTrue("stdout should contain '" + COOKIE_PERSISTENT_CHECK + "' but did not.", pr.stdout.contains(COOKIE_PERSISTENT_CHECK)); -
trunk/icedtea-web/tests/reproducers/signed/SignedJnlpApplication/testcases/SignedJnlpApplicationTest.java
r418 r429 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 43 42 44 import org.junit.Assert; 43 45 import org.junit.Test; … … 53 55 @Test 54 56 public void launchingFileMatchesSignedApplication1() throws Exception { 55 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication1.jnlp");57 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication1.jnlp"); 56 58 String s = "Running signed application in main"; 57 59 Assert.assertTrue("Stdout should contains " + s + " but did not", pr.stdout.contains(s)); … … 63 65 @Test 64 66 public void launchingFileDoesNotMatchSignedApplication1() throws Exception { 65 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication2.jnlp");67 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication2.jnlp"); 66 68 Assert.assertTrue("Stderr should contains " + signedException + " but did not", pr.stderr.contains(signedException)); 67 69 } … … 72 74 @Test 73 75 public void launchingFileDoesNotMatchSignedApplication2() throws Exception { 74 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication3.jnlp");76 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpApplication3.jnlp"); 75 77 Assert.assertTrue("Stderr should contains " + signedException + " but did not", pr.stderr.contains(signedException)); 76 78 } -
trunk/icedtea-web/tests/reproducers/signed/SignedJnlpCaseTestOne/testcases/SignedJnlpCaseOneTest.java
r418 r429 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 43 42 44 import org.junit.Assert; 43 45 import org.junit.Test; … … 50 52 @Test 51 53 public void launchingFileMatchesSigned() throws Exception { 52 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestOne1.jnlp");54 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestOne1.jnlp"); 53 55 String s = "Running signed application in main"; 54 56 Assert.assertTrue("Stdout should contains " + s + " but did not", pr.stdout.contains(s)); … … 57 59 @Test 58 60 public void launchingFileDoesNotMatchSigned() throws Exception { 59 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestOne2.jnlp");61 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestOne2.jnlp"); 60 62 String s = "net.sourceforge.jnlp.LaunchException: Fatal: Application Error: The signed " + 61 63 "JNLP file did not match the launching JNLP file. Missing Resource: Signed Application did not match " + -
trunk/icedtea-web/tests/reproducers/signed/SignedJnlpCaseTestTwo/testcases/SignedJnlpCaseTwoTest.java
r418 r429 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 42 43 import org.junit.Assert; … … 50 51 @Test 51 52 public void launchingFileMatchesSigned() throws Exception { 52 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestTwo1.jnlp");53 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestTwo1.jnlp"); 53 54 String s = "Running signed application in main"; 54 55 Assert.assertTrue("Stdout should contains " + s + " but did not", pr.stdout.contains(s)); … … 57 58 @Test 58 59 public void launchingFileDoesNotMatchSigned() throws Exception { 59 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestTwo2.jnlp");60 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpCaseTestTwo2.jnlp"); 60 61 String s = "net.sourceforge.jnlp.LaunchException: Fatal: Application Error: The signed " + 61 62 "JNLP file did not match the launching JNLP file. Missing Resource: Signed Application did not match " + -
trunk/icedtea-web/tests/reproducers/signed/SignedJnlpTemplate/testcases/SignedJnlpTemplateTest.java
r418 r429 39 39 import java.util.Collections; 40 40 import java.util.List; 41 import net.sourceforge.jnlp.ProcessResult; 41 42 import net.sourceforge.jnlp.ServerAccess; 43 42 44 import org.junit.Assert; 43 45 import org.junit.Test; … … 53 55 @Test 54 56 public void launchingFileMatchesSignedTemplate1() throws Exception { 55 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate1.jnlp");57 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate1.jnlp"); 56 58 String s = "Running signed application in main"; 57 59 Assert.assertTrue("Stdout should contains " + s + " but did not", pr.stdout.contains(s)); … … 63 65 @Test 64 66 public void launchingFileDoesNotMatchSignedTemplate2() throws Exception { 65 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate2.jnlp");67 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate2.jnlp"); 66 68 Assert.assertTrue("Stderr should contains " + signedException + " but did not", pr.stderr.contains(signedException)); 67 69 } … … 72 74 @Test 73 75 public void launchingFileDoesNotMatchSignedTemplate3() throws Exception { 74 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate3.jnlp");76 ProcessResult pr = server.executeJavawsHeadless(l, "/SignedJnlpTemplate3.jnlp"); 75 77 Assert.assertTrue("Stderr should contains " + signedException + " but did not", pr.stderr.contains(signedException)); 76 78 } -
trunk/icedtea-web/tests/reproducers/signed/Spaces can be everywhere signed/testcases/SpacesCanBeEverywhereTestsSigned.java
r418 r429 38 38 import java.util.ArrayList; 39 39 import java.util.List; 40 import net.sourceforge.jnlp.ProcessResult; 40 41 import net.sourceforge.jnlp.ServerAccess; 41 42 import net.sourceforge.jnlp.annotations.Bug; … … 44 45 import net.sourceforge.jnlp.browsertesting.Browsers; 45 46 import net.sourceforge.jnlp.annotations.TestInBrowsers; 47 46 48 import org.junit.Assert; 47 48 49 import org.junit.Test; 49 50 50 51 @Bug(id={"http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2011-October/016127.html","PR804","PR811"}) 51 52 public class SpacesCanBeEverywhereTestsSigned extends BrowserTest { 52 53 53 54 54 @Bug(id="PR811") … … 83 83 * only on ocal files, and probably only from test run - it can be ignored 84 84 */ 85 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands); 86 String s="Signed spaces can be everywhere.jsr was launched correctly"; 87 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 88 String cc = "xception"; 89 Assert.assertFalse("stderr should NOT contains `" + cc + "`, but did", pr.stderr.contains(cc)); 85 ProcessResult pr = ServerAccess.executeProcess(commands); 86 String s="Signed spaces can be everywhere.jsr was launched correctly"; 87 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 90 88 Assert.assertFalse("should not be terminated, but was", pr.wasTerminated); 91 89 Assert.assertEquals((Integer) 0, pr.returnValue); … … 96 94 @NeedsDisplay 97 95 public void SpacesCanBeEverywhereRemoteAppletTestsJnlp2Signed() throws Exception { 98 ServerAccess.ProcessResult pr = server.executeJavaws("/NotOnly%20spaces%20can%20kill%20%C4%9B%C5%A1%C4%8D%C5%99%C5%BE%20too%20signed.jnlp"); 99 String s="Signed spaces can be everywhere.jsr was launched correctly"; 100 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 101 String cc = "xception"; 102 Assert.assertFalse("stderr should NOT contains `" + cc + "`, but did", pr.stderr.contains(cc)); 96 ProcessResult pr = server.executeJavaws("/NotOnly%20spaces%20can%20kill%20%C4%9B%C5%A1%C4%8D%C5%99%C5%BE%20too%20signed.jnlp"); 97 String s="Signed spaces can be everywhere.jsr was launched correctly"; 98 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 103 99 Assert.assertFalse("should NOT be terminated, but was not", pr.wasTerminated); 104 100 } … … 109 105 @TestInBrowsers(testIn = {Browsers.one}) 110 106 public void SpacesCanBeEverywhereRemoteAppletTestsHtml2Signed() throws Exception { 111 ServerAccess.ProcessResult pr = server.executeBrowser("/spaces+applet+Tests+signed.html"); 112 String s="Signed spaces can be everywhere.jsr was launched correctly"; 113 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 114 String cc = "xception"; 115 Assert.assertFalse("stderr should NOT contains `" + cc + "`, but did", pr.stderr.contains(cc)); 107 ProcessResult pr = server.executeBrowser("/spaces+applet+Tests+signed.html"); 108 String s="Signed spaces can be everywhere.jsr was launched correctly"; 109 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); 116 110 Assert.assertTrue("should be terminated, but was not", pr.wasTerminated); 117 111 } … … 121 115 @Test 122 116 public void SpacesCanBeEverywhereRemoteTests1Signed() throws Exception { 123 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere1%20signed.jnlp");117 ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere1%20signed.jnlp"); 124 118 String s = "Good simple javaws exapmle"; 125 119 Assert.assertTrue("stdout should contains `" + s + "`, but did not", pr.stdout.contains(s)); … … 133 127 @Test 134 128 public void SpacesCanBeEverywhereRemoteTests2Signed() throws Exception { 135 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp");129 ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp"); 136 130 String s="Signed spaces can be everywhere.jsr was launched correctly"; 137 131 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); … … 145 139 @Test 146 140 public void SpacesCanBeEverywhereRemoteTests2Signed_withQuery1() throws Exception { 147 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp?test=20");141 ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp?test=20"); 148 142 String s="Signed spaces can be everywhere.jsr was launched correctly"; 149 143 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); … … 157 151 @Test 158 152 public void SpacesCanBeEverywhereRemoteTests2Signed_withQuery2() throws Exception { 159 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp?test%3D20");153 ProcessResult pr = server.executeJavawsHeadless(null, "/Spaces%20can%20be%20everywhere2%20signed.jnlp?test%3D20"); 160 154 161 155 String s="Signed spaces can be everywhere.jsr was launched correctly"; … … 170 164 @Test 171 165 public void SpacesCanBeEverywhereRemoteTests3Signed() throws Exception { 172 ServerAccess.ProcessResult pr = server.executeJavawsHeadless(null, "/SpacesCanBeEverywhere1signed.jnlp");166 ProcessResult pr = server.executeJavawsHeadless(null, "/SpacesCanBeEverywhere1signed.jnlp"); 173 167 String s="Signed spaces can be everywhere.jsr was launched correctly"; 174 168 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); … … 187 181 commands.add(ServerAccess.HEADLES_OPTION); 188 182 commands.add("Spaces can be everywhere1.jnlp"); 189 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir());183 ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir()); 190 184 String s = "Good simple javaws exapmle"; 191 185 Assert.assertTrue("stdout should contains `" + s + "`, but did not", pr.stdout.contains(s)); … … 203 197 commands.add(ServerAccess.HEADLES_OPTION); 204 198 commands.add("Spaces can be everywhere2 signed.jnlp"); 205 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir());199 ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir()); 206 200 String s="Signed spaces can be everywhere.jsr was launched correctly"; 207 201 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); … … 219 213 commands.add(ServerAccess.HEADLES_OPTION); 220 214 commands.add(server.getDir()+"/Spaces can be everywhere2 signed.jnlp"); 221 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands);215 ProcessResult pr = ServerAccess.executeProcess(commands); 222 216 String s="Signed spaces can be everywhere.jsr was launched correctly"; 223 217 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s)); … … 235 229 commands.add(ServerAccess.HEADLES_OPTION); 236 230 commands.add("SpacesCanBeEverywhere1signed.jnlp"); 237 ServerAccess.ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir());231 ProcessResult pr = ServerAccess.executeProcess(commands,server.getDir()); 238 232 String s="Signed spaces can be everywhere.jsr was launched correctly"; 239 233 Assert.assertTrue("stdout should contains `"+s+"`, but did not",pr.stdout.contains(s));
Note:
See TracChangeset
for help on using the changeset viewer.