diff options
author | Dwayne Boone <dwayne@zeroc.com> | 2015-10-01 16:27:11 -0230 |
---|---|---|
committer | Dwayne Boone <dwayne@zeroc.com> | 2015-10-01 16:27:11 -0230 |
commit | 36a9c67e6a0832a50d64f39f5bfd328beb56e989 (patch) | |
tree | efbf378ddba4c84aad86d3306b61d3c8b22fab3e /js/test | |
parent | Fixed missing lib directory for RPATH on install of Py/Ruby/Php modules (diff) | |
download | ice-36a9c67e6a0832a50d64f39f5bfd328beb56e989.tar.bz2 ice-36a9c67e6a0832a50d64f39f5bfd328beb56e989.tar.xz ice-36a9c67e6a0832a50d64f39f5bfd328beb56e989.zip |
ICE-6767 Better handling of server start failure by test controller
Diffstat (limited to 'js/test')
-rw-r--r-- | js/test/Common/Controller.ice | 10 | ||||
-rw-r--r-- | js/test/Common/TestRunner.js | 19 |
2 files changed, 21 insertions, 8 deletions
diff --git a/js/test/Common/Controller.ice b/js/test/Common/Controller.ice index 0508b4826da..7e4c2b95eda 100644 --- a/js/test/Common/Controller.ice +++ b/js/test/Common/Controller.ice @@ -13,10 +13,15 @@ module Test module Common { +exception ServerFailedException +{ + string reason; +}; + interface Server { void waitTestSuccess(); - void waitForServer(); + void waitForServer() throws ServerFailedException; void terminate(); }; @@ -24,8 +29,7 @@ sequence<string> StringSeq; interface Controller { - Server* runServer(string lang, string name, string protocol, string host, bool winrt, - StringSeq options); + Server* runServer(string lang, string name, string protocol, string host, bool winrt, StringSeq options); }; }; diff --git a/js/test/Common/TestRunner.js b/js/test/Common/TestRunner.js index 75a960644ed..a1f51d19440 100644 --- a/js/test/Common/TestRunner.js +++ b/js/test/Common/TestRunner.js @@ -21,7 +21,7 @@ function isSafari() function isWorker() { - return typeof(WorkerGlobalScope) !== 'undefined' && this instanceof WorkerGlobalScope; + return typeof(WorkerGlobalScope) !== 'undefined' && this instanceof WorkerGlobalScope; } function runTest(name, language, defaultHost, protocol, configurations, out) @@ -86,7 +86,8 @@ function runTest(name, language, defaultHost, protocol, configurations, out) var initData = id.clone(); if(configuration.args !== undefined) { - initData.properties = Ice.createProperties(configuration.args, id.properties); + initData.properties = + Ice.createProperties(configuration.args, id.properties); } return __test__(out, initData); }); @@ -154,10 +155,18 @@ function runTest(name, language, defaultHost, protocol, configurations, out) { out.writeLine("exception occurred in call to " + r.operation); } - out.writeLine(ex.toString()); - if(ex.stack) + if(ex instanceof Test.Common.ServerFailedException) { - out.writeLine(ex.stack); + out.writeLine("Server failed to start:\n"); + out.writeLine(ex.reason); + } + else + { + out.writeLine(ex.toString()); + if(ex.stack) + { + out.writeLine(ex.stack); + } } return false; }); |