diff options
author | Jiri Vanek <[email protected]> | 2013-04-19 16:41:33 +0200 |
---|---|---|
committer | Jiri Vanek <[email protected]> | 2013-04-19 16:41:33 +0200 |
commit | 2307dedd17d10a7a32cd4180dc4b36f86a26dcc1 (patch) | |
tree | bbc3cc364136e3c63f76e42d00228e7026d705e9 /tests | |
parent | c7dfa1accef2adc31170a79505f690f0037fd4f9 (diff) |
testing server allowed from makefile
* Makefile.am:
(stamps/netx-dist-tests-prepare-reproducers.stamp) added stamps/netx-dist.stamp stamps/plugin.stamp dependence
(stamps/test-extensions-compile.stamp) added stamps/netx-dist.stamp stamps/plugin.stamp dependence
(stamps/compile-reproducers-testcases.stamp) added stamps/plugin.stamp dependence
(run-test-server-on-44321) new target, starts server in deploy dir, on port 44321
(run-test-server-on-random-port) new target, starts server in deploy dir, on random port
* tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java: (main)
added better access to random port
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java b/tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java index 6804faa..55ec17a 100644 --- a/tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java +++ b/tests/test-extensions/net/sourceforge/jnlp/ServerAccess.java @@ -138,8 +138,10 @@ public class ServerAccess { System.exit(0); } else { int port = 44321; - if (args.length > 0) { - port=new Integer(args[0]); + if (args.length > 0 && args[0].equalsIgnoreCase("randomport")) { + port = findFreePort(); + } else if (args.length > 0) { + port = new Integer(args[0]); } getIndependentInstance(port); while (true) { |