diff options
author | Jose <jose@zeroc.com> | 2017-04-14 15:53:44 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2017-04-14 15:53:44 +0200 |
commit | 143f66813fc76abd4941f9bf2079cd3b92ab61fe (patch) | |
tree | b9d4022213a996693926d8bcff371bf91171dd38 | |
parent | Add icegrid to icegridadmin MSBuild dependencies (diff) | |
download | ice-143f66813fc76abd4941f9bf2079cd3b92ab61fe.tar.bz2 ice-143f66813fc76abd4941f9bf2079cd3b92ab61fe.tar.xz ice-143f66813fc76abd4941f9bf2079cd3b92ab61fe.zip |
Minor JS fixes
27 files changed, 141 insertions, 102 deletions
diff --git a/js/gulpfile.js b/js/gulpfile.js index 342b4a513fb..27ace9090fc 100644 --- a/js/gulpfile.js +++ b/js/gulpfile.js @@ -31,7 +31,7 @@ var babel = require("gulp-babel"), var sliceDir = path.resolve(__dirname, '..', 'slice'); var iceBinDist = (process.env.ICE_BIN_DIST || "").split(" "); -var useBinDist = iceBinDist.find(function(variable) {return variable == "js" || variable == "all" }) !== undefined; +var useBinDist = iceBinDist.find(function(v) { return v == "js" || v == "all"; }) !== undefined; function parseArg(argv, key) { @@ -42,7 +42,7 @@ function parseArg(argv, key) { return argv[i + 1]; } - else if(e.indexOf(key + "=") == 0) + else if(e.indexOf(key + "=") === 0) { return e.substr(key.length + 1); } @@ -561,7 +561,7 @@ gulp.task("ice-module:clean", [], { return gulp.src(['node_modules/ice']).pipe(paths(del)); }); - cleanDepends.push("ice-module:clean") + cleanDepends.push("ice-module:clean"); } gulp.task("lint", ["lint:js", "lint:html"]); diff --git a/js/src/Ice/IncomingAsync.js b/js/src/Ice/IncomingAsync.js index 4ef1526eb44..cd03834bf9f 100644 --- a/js/src/Ice/IncomingAsync.js +++ b/js/src/Ice/IncomingAsync.js @@ -522,7 +522,7 @@ class IncomingAsync Debug.assert(this._connection !== null); - if(exc != null) + if(exc !== null) { this.handleException(exc, amd); } diff --git a/js/src/Ice/Instance.js b/js/src/Ice/Instance.js index 863ac578055..7e3ca7e704b 100644 --- a/js/src/Ice/Instance.js +++ b/js/src/Ice/Instance.js @@ -359,11 +359,11 @@ class Instance const toStringModeStr = this._initData.properties.getPropertyWithDefault("Ice.ToStringMode", "Unicode"); if(toStringModeStr === "ASCII") { - _toStringMode = Ice.ToStringMode.ASCII; + this._toStringMode = Ice.ToStringMode.ASCII; } else if(toStringModeStr === "Compat") { - _toStringMode = Ice.ToStringMode.Compat; + this._toStringMode = Ice.ToStringMode.Compat; } else if(toStringModeStr !== "Unicode") { diff --git a/js/src/Ice/Long.js b/js/src/Ice/Long.js index cf748c8c4ba..02fab7929bc 100644 --- a/js/src/Ice/Long.js +++ b/js/src/Ice/Long.js @@ -23,7 +23,7 @@ class Long // If two arguments are provided we asume these are the high and low words // respectively. // - constructor(high = 0, low) + constructor(high = 0, low = undefined) { if(!Number.isSafeInteger(high)) { @@ -90,7 +90,7 @@ class Long { return Number.NEGATIVE_INFINITY; } - return -((h * Long.HIGH_MASK) + l + 1) + return -((h * Long.HIGH_MASK) + l + 1); } else { diff --git a/js/src/Ice/StringUtil.js b/js/src/Ice/StringUtil.js index 0f125dc3e02..875a8be63ca 100644 --- a/js/src/Ice/StringUtil.js +++ b/js/src/Ice/StringUtil.js @@ -419,7 +419,7 @@ function checkChar(s, pos) msg += " has invalid ordinal value" + c; throw new Error(msg); } - return s.charAt(pos) + return s.charAt(pos); } // // Decode the character or escape sequence starting at start and appends it to result; @@ -483,13 +483,13 @@ function decodeChar(s, start, end, special, result) case 'r': { ++start; - result.push("\r") + result.push("\r"); break; } case 't': { ++start; - result.push("\t") + result.push("\t"); break; } case 'v': diff --git a/js/src/Ice/Value.js b/js/src/Ice/Value.js index 93431f950f3..04a1fbbfcd7 100644 --- a/js/src/Ice/Value.js +++ b/js/src/Ice/Value.js @@ -172,8 +172,7 @@ function readPreserved(is) is.startValue(); readImpl(this, is, this._iceMostDerivedType()); this._iceSlicedData = is.endValue(true); -}; - +} const Slice = Ice.Slice; @@ -188,17 +187,17 @@ Slice.defineValue = function(valueType, id, preserved, compactId = 0) valueType.prototype.ice_id = function() { return id; - } + }; valueType.prototype._iceMostDerivedType = function() { return valueType; - } + }; valueType.ice_staticId = function() { return id; - } + }; if(preserved) { @@ -210,7 +209,7 @@ Slice.defineValue = function(valueType, id, preserved, compactId = 0) { Ice.CompactIdRegistry.set(compactId, id); } -} +}; Slice.defineValue(Ice.Value, "::Ice::Object"); module.exports.Ice = Ice;
\ No newline at end of file diff --git a/js/src/Ice/browser/ModuleRegistry.js b/js/src/Ice/browser/ModuleRegistry.js index 006b28a937f..ac1d676d2c4 100644 --- a/js/src/Ice/browser/ModuleRegistry.js +++ b/js/src/Ice/browser/ModuleRegistry.js @@ -7,9 +7,15 @@ // // ********************************************************************** -/* globals self */ -const root = typeof(window) !== "undefined" ? window : typeof(global) !== "undefined" ? global : typeof(self) !== "undefined" ? self : {}; -/* globals -self */ +/* global + self : false +*/ +const root = typeof(window) !== "undefined" ? window : + typeof(global) !== "undefined" ? global : + typeof(self) !== "undefined" ? self : {}; +/* global + self : true +*/ class _ModuleRegistry { diff --git a/js/test/Common/.jshintrc b/js/test/Common/.jshintrc index 7e7906b21af..ffa6d1cc5f8 100644 --- a/js/test/Common/.jshintrc +++ b/js/test/Common/.jshintrc @@ -1,3 +1,7 @@ { - "extends" : "../../.jshintrc_browser" + "extends" : "../../.jshintrc_browser", + "globals" : + { + "runController" : false + } } diff --git a/js/test/Common/ControllerI.js b/js/test/Common/ControllerI.js index 03da1e67ca8..220317b498d 100644 --- a/js/test/Common/ControllerI.js +++ b/js/test/Common/ControllerI.js @@ -7,6 +7,16 @@ // // ********************************************************************** + /* global + _test : false, + _runServer : false, + Test : false, + WorkerGlobalScope : false, + _server: false, + _serveramd: false, + URI: false +*/ + var process = { argv : [] }; function isSafari() @@ -37,8 +47,8 @@ class Logger extends Ice.Logger { constructor(out) { - super() - this._out = out + super(); + this._out = out; } write(message, indent) @@ -85,7 +95,7 @@ class ProcessI extends Test.Common.Process current.adapter.remove(current.id); return this._output.get(); } -}; +} class ProcessControllerI extends Test.Common.ProcessController { @@ -154,14 +164,14 @@ class ProcessControllerI extends Test.Common.ProcessController worker.terminate(); } }; - worker.postMessage({ scripts:scripts, exe:exe, args:args }) + worker.postMessage({ scripts:scripts, exe:exe, args:args }); }); } else { let initData = new Ice.InitializationData(); initData.properties = Ice.createProperties(args); - process.argv = args + process.argv = args; if(exe === "Server" || exe === "ServerAMD") { initData.logger = new Logger(this._serverOutput); @@ -179,9 +189,9 @@ class ProcessControllerI extends Test.Common.ProcessController getHost(protocol, ipv6, current) { - return "127.0.0.1" + return "127.0.0.1"; } -}; +} function runController(clientOutput, serverOutput, scripts) { @@ -202,7 +212,7 @@ function runController(clientOutput, serverOutput, scripts) }, get: function() { - return output.val() + return output.val(); }, clear : function() { @@ -224,19 +234,19 @@ function runController(clientOutput, serverOutput, scripts) return false; }; - let uri = new URI(document.location.href) + let uri = new URI(document.location.href); let initData = new Ice.InitializationData(); let protocol = uri.protocol() === "http" ? "ws" : "wss"; - query = uri.search(true) - let port = "port" in query ? query["port"] : 15002; - let worker = "worker" in query ? query["worker"] === "True" : false; + let query = uri.search(true); + let port = query.port || 15002; + let worker = query.worker === "True" ? true : false; initData.logger = new Logger(out); let registerProcessController = function(adapter, registry, processController) { registry.setProcessController(Test.Common.ProcessControllerPrx.uncheckedCast(processController)).then( () => { let connection = registry.ice_getCachedConnection(); - connection.setAdapter(adapter) + connection.setAdapter(adapter); connection.setACM(5, Ice.ACMClose.CloseOff, Ice.ACMHeartbeat.HeartbeatAlways); connection.setCloseCallback(connection => { out.writeLine("connection with process controller registry closed"); @@ -249,7 +259,7 @@ function runController(clientOutput, serverOutput, scripts) } else { - out.writeLine("unexpected exception while connecting to process controller registry:\n" + ex.toString()) + out.writeLine("unexpected exception while connecting to process controller registry:\n" + ex.toString()); } }); }; diff --git a/js/test/Common/ControllerWorker.js b/js/test/Common/ControllerWorker.js index e763254e6c1..42ff436b62d 100644 --- a/js/test/Common/ControllerWorker.js +++ b/js/test/Common/ControllerWorker.js @@ -9,7 +9,10 @@ /* global self : false, - runTest : false + runTest : false, + _server : false, + _serveramd : false, + _test : false */ var process = { argv : [] }; @@ -38,8 +41,8 @@ self.onmessage = function(e) { constructor(out) { - super() - this._out = out + super(); + this._out = out; } write(message, indent) @@ -52,7 +55,7 @@ self.onmessage = function(e) } } - let promise + let promise; let initData = new Ice.InitializationData(); initData.properties = Ice.createProperties(e.data.args); initData.logger = new Logger(out); diff --git a/js/test/Common/TestRunner.js b/js/test/Common/TestRunner.js index 8fa5f6d1978..8d6903b0fff 100644 --- a/js/test/Common/TestRunner.js +++ b/js/test/Common/TestRunner.js @@ -11,7 +11,9 @@ /* global _test : false, _runServer : false, + _server: false, Test : false, + WorkerGlobalScope: false */ var process = { argv : [] }; @@ -131,7 +133,7 @@ function runTest(testsuite, language, host, protocol, testcases, out) testcases = [ { name: "client/server" } ]; } - run = function(testcase, client) + var run = function(testcase, client) { if(testcase.langs && testcase.langs.indexOf(language) == -1) { @@ -146,7 +148,7 @@ function runTest(testsuite, language, host, protocol, testcases, out) } else { - runTestCase = function() { return controller.runTestCase("js", testsuite, testcase.name, language) }; + runTestCase = function() { return controller.runTestCase("js", testsuite, testcase.name, language); }; } out.write("starting server side... "); var serverTestCase; @@ -154,7 +156,7 @@ function runTest(testsuite, language, host, protocol, testcases, out) return runTestCase().then( function(proxy) { - proxy = controller.ice_getCachedConnection().createProxy(proxy.ice_getIdentity()) + proxy = controller.ice_getCachedConnection().createProxy(proxy.ice_getIdentity()); serverTestCase = Test.Common.TestCasePrx.uncheckedCast(proxy); var config = new Test.Common.Config(); config.protocol = protocol; @@ -163,7 +165,7 @@ function runTest(testsuite, language, host, protocol, testcases, out) ).then( function() { - out.writeLine("ok") + out.writeLine("ok"); process.argv = testcase.args; if(language === "js") { @@ -172,8 +174,8 @@ function runTest(testsuite, language, host, protocol, testcases, out) { initData.properties = Ice.createProperties(testcase.args, id.properties); } - ready = new Ice.Promise(); - server = _server(out, initData.clone(), ready) + var ready = new Ice.Promise(); + server = _server(out, initData.clone(), ready); return ready; } } @@ -204,7 +206,7 @@ function runTest(testsuite, language, host, protocol, testcases, out) function(ex) { out.writeLine("failed! (" + ex + ")"); - throw ex + throw ex; } ).finally( function() @@ -214,11 +216,11 @@ function runTest(testsuite, language, host, protocol, testcases, out) return serverTestCase.destroy(); } }); - } + }; var p = Ice.Promise.resolve(); testcases.forEach(function(testcase) { - p = p.then(function() { return run(testcase, _test); }) + p = p.then(function() { return run(testcase, _test); }); }); return p; } diff --git a/js/test/Common/Worker.js b/js/test/Common/Worker.js index eb79ba401ad..19e42a099f4 100644 --- a/js/test/Common/Worker.js +++ b/js/test/Common/Worker.js @@ -44,7 +44,7 @@ self.onmessage = function(e) self.importScripts("/test/Common/TestRunner.js"); for(var i = 0; i < test.files.length; ++i) { - var f = test.files[i] + var f = test.files[i]; if(f.indexOf("/") === -1) { f = "/test/" + test.name + "/" + f; diff --git a/js/test/Common/run.js b/js/test/Common/run.js index 105085ef5f2..90f457c1e93 100755 --- a/js/test/Common/run.js +++ b/js/test/Common/run.js @@ -7,10 +7,10 @@ // // ********************************************************************** -var es5 = process.argv[2] === "--es5" +var es5 = process.argv[2] === "--es5"; if(es5) { - process.argv.splice(2, 1) + process.argv.splice(2, 1); } var Ice = require(es5 ? "ice/src/es5" : "ice").Ice; @@ -37,16 +37,16 @@ var exception = function(ex) var id = new Ice.InitializationData(); id.properties = Ice.createProperties(process.argv); -exe = process.argv[2] -var test = module.require(exe) +var exe = process.argv[2]; +var test = module.require(exe); if(exe === "Server" || exe === "ServerAMD") { var ready = new Ice.Promise(); test = exe === "Server" ? test._server : test._serveramd; - test({write: write, writeLine: writeLine}, id, ready).catch(exception) + test({write: write, writeLine: writeLine}, id, ready).catch(exception); ready.then(() => console.log("server ready")); } else { - test._test({write: write, writeLine: writeLine}, id).catch(exception) -}
\ No newline at end of file + test._test({write: write, writeLine: writeLine}, id).catch(exception); +} diff --git a/js/test/Glacier2/router/Client.js b/js/test/Glacier2/router/Client.js index 79ceee576dc..0c8496d7782 100644 --- a/js/test/Glacier2/router/Client.js +++ b/js/test/Glacier2/router/Client.js @@ -381,7 +381,7 @@ ); } } - ) + ); }; var run = function(out, id) diff --git a/js/test/Ice/ami/Client.js b/js/test/Ice/ami/Client.js index fae8319b5d4..b535c51ce38 100644 --- a/js/test/Ice/ami/Client.js +++ b/js/test/Ice/ami/Client.js @@ -7,6 +7,11 @@ // // ********************************************************************** +/* global + isSafari : false, + isWorker : false +*/ + (function(module, require, exports) { var Ice = require("ice").Ice; @@ -21,6 +26,7 @@ { try { + console.log(new Error().stack); throw new Error("test failed"); } catch(err) @@ -204,7 +210,7 @@ { var r1 = p.op(); var r2 = null; - var seq = new Uint8Array(100000); + var seq = new Uint8Array(); while((r2 = p.opWithPayload(seq)).sentSynchronously()); test(r1.sentSynchronously() && r1.isSent() && !r1.isCompleted() || @@ -278,7 +284,7 @@ ).then(() => testController.holdAdapter() ).then(() => { - var seq = new Uint8Array(100000); + var seq = new Uint8Array(new Array(100000)); while((r = p.opWithPayload(seq)).sentSynchronously()); test(!r.isSent()); diff --git a/js/test/Ice/binding/Client.js b/js/test/Ice/binding/Client.js index 95e678f9dd5..4300d9ca48f 100644 --- a/js/test/Ice/binding/Client.js +++ b/js/test/Ice/binding/Client.js @@ -7,6 +7,11 @@ // // ********************************************************************** +/* global + isSafari : false, + isWorker : false +*/ + (function(module, require, exports) { var Ice = require("ice").Ice; @@ -186,7 +191,7 @@ }, function(ex) { - test(isConnectionFailed(ex)) + test(isConnectionFailed(ex)); out.writeLine("ok"); return initialize(); } @@ -865,7 +870,7 @@ ).then( function() { - var test3 = Test.TestIntfPrx.uncheckedCast(test1); + let test3 = Test.TestIntfPrx.uncheckedCast(test1); return Ice.Promise.all([test3.ice_getConnection(), test1.ice_getConnection()]); } @@ -876,7 +881,7 @@ }, function(ex) { - test(isConnectionFailed(ex)) + test(isConnectionFailed(ex)); }); }; return f1(); @@ -1043,7 +1048,7 @@ }, function(ex) { - test(isConnectionFailed(ex)) + test(isConnectionFailed(ex)); return prx.ice_getEndpoints(); } ).then( diff --git a/js/test/Ice/enums/Client.js b/js/test/Ice/enums/Client.js index f13e376266c..21c01452c1d 100644 --- a/js/test/Ice/enums/Client.js +++ b/js/test/Ice/enums/Client.js @@ -29,7 +29,7 @@ throw err; } } - }; + } let base, proxy; Ice.Promise.try(() => @@ -199,13 +199,13 @@ ).then(p.resolve, p.reject); return p; - }; + } function run(out, id) { var c = Ice.initialize(id); return Ice.Promise.try(() => allTests(out, c)).finally(() => c.destroy()); - }; + } exports._test = run; exports._runServer = true; } diff --git a/js/test/Ice/exceptions/Server.js b/js/test/Ice/exceptions/Server.js index ffb45677831..1055431da89 100644 --- a/js/test/Ice/exceptions/Server.js +++ b/js/test/Ice/exceptions/Server.js @@ -36,7 +36,7 @@ var connection = echo.ice_getCachedConnection(); connection.setCloseCallback((con) => { // Re-establish connection if it fails (necessary for MemoryLimitException test) - echo.setConnection().then(() => echo.ice_getCachedConnection().setAdapter(adapter)) + echo.setConnection().then(() => echo.ice_getCachedConnection().setAdapter(adapter)); }); connection.setAdapter(adapter); adapter.activate(); diff --git a/js/test/Ice/exceptions/ServerAMD.js b/js/test/Ice/exceptions/ServerAMD.js index f6383f2ee3d..493b3c71d26 100644 --- a/js/test/Ice/exceptions/ServerAMD.js +++ b/js/test/Ice/exceptions/ServerAMD.js @@ -36,7 +36,7 @@ var connection = echo.ice_getCachedConnection(); connection.setCloseCallback((con) => { // Re-establish connection if it fails (necessary for MemoryLimitException test) - echo.setConnection().then(() => echo.ice_getCachedConnection().setAdapter(adapter)) + echo.setConnection().then(() => echo.ice_getCachedConnection().setAdapter(adapter)); }); connection.setAdapter(adapter); echo.ice_getCachedConnection().setAdapter(adapter); diff --git a/js/test/Ice/facets/Server.js b/js/test/Ice/facets/Server.js index 1c34aeac407..8f4512ee175 100644 --- a/js/test/Ice/facets/Server.js +++ b/js/test/Ice/facets/Server.js @@ -28,7 +28,6 @@ } catch(err) { - p.reject(err); throw err; } } diff --git a/js/test/Ice/import/main.js b/js/test/Ice/import/main.js index e7e0871d7c0..748a84ef699 100644 --- a/js/test/Ice/import/main.js +++ b/js/test/Ice/import/main.js @@ -15,10 +15,10 @@ function test(value) } } -console.log("testing import/export modules") -let point = new Demo.gx.Point(10, 10) -test(point.x == 10); -test(point.y == 10); +console.log("testing import/export modules"); +let point = new Demo.gx.Point(10, 10); +test(point.x === 10); +test(point.y === 10); let circle = new Demo.gx.Circle(new Demo.gx.Point(10, 10), 100); test(circle.center.x == 10); @@ -31,27 +31,27 @@ let square = new Demo.gx.Square( new Demo.gx.Point(10, 10), new Demo.gx.Point(0, 10)); -test(square.p1.x == 0); -test(square.p1.y == 0); +test(square.p1.x === 0); +test(square.p1.y === 0); -test(square.p2.x == 10); -test(square.p2.y == 0); +test(square.p2.x === 10); +test(square.p2.y === 0); -test(square.p3.x == 10); -test(square.p3.y == 10); +test(square.p3.x === 10); +test(square.p3.y === 10); -test(square.p4.x == 0); -test(square.p4.y == 10); +test(square.p4.x === 0); +test(square.p4.y === 10); let communicator = Ice.initialize(); let session = Demo.gx.SessionPrx.uncheckedCast(communicator.stringToProxy("demo:default -h 127.0.0.1")); -test(session != undefined); +test(session !== undefined); let canvas = Demo.gx.CanvasPrx.uncheckedCast(communicator.stringToProxy("demo:default -h 127.0.0.1")); -test(canvas != undefined); +test(canvas !== undefined); communicator.destroy().then( function() { - console.log("ok") + console.log("ok"); }); diff --git a/js/test/Ice/objects/Client.js b/js/test/Ice/objects/Client.js index 3c98a5451c7..1ecf83e6e02 100644 --- a/js/test/Ice/objects/Client.js +++ b/js/test/Ice/objects/Client.js @@ -398,10 +398,10 @@ return loop(depth => { p.v = new Test.Recursive(); p = p.v; - if((depth < 10 && (depth % 10) == 0) || - (depth < 1000 && (depth % 100) == 0) || - (depth < 10000 && (depth % 1000) == 0) || - (depth % 10000) == 0) + if((depth < 10 && (depth % 10) === 0) || + (depth < 1000 && (depth % 100) === 0) || + (depth < 10000 && (depth % 1000) === 0) || + (depth % 10000) === 0) { return initial.setRecursive(top); } diff --git a/js/test/Ice/objects/InitialI.js b/js/test/Ice/objects/InitialI.js index e8cd5c4a3db..4b8e287b73b 100644 --- a/js/test/Ice/objects/InitialI.js +++ b/js/test/Ice/objects/InitialI.js @@ -31,7 +31,7 @@ { this.postUnmarshalInvoked = true; } - }; + } class CI extends Test.C { @@ -44,7 +44,7 @@ { this.postUnmarshalInvoked = true; } - }; + } class DI extends Test.D { @@ -57,7 +57,7 @@ { this.postUnmarshalInvoked = true; } - }; + } class EI extends Test.E { @@ -70,7 +70,7 @@ { return this.i == 1 && this.s == "hello"; } - }; + } class FI extends Test.F { @@ -83,11 +83,11 @@ { return this.e1 !== null && this.e1 === this.e2; } - }; + } class HI extends Test.H { - }; + } class II extends Ice.InterfaceByValue { @@ -95,7 +95,7 @@ { super(Test.I.ice_staticId()); } - }; + } class JI extends Ice.InterfaceByValue { @@ -103,7 +103,7 @@ { super(Test.J.ice_staticId()); } - }; + } function MyValueFactory(type) { @@ -182,7 +182,7 @@ this._b2.preMarshalInvoked = false; this._c.preMarshalInvoked = false; this._d.preMarshalInvoked = false; - return [this._b1, this._b2, this._c, this._d] + return [this._b1, this._b2, this._c, this._d]; } getB1(current) diff --git a/js/test/Ice/objects/Server.js b/js/test/Ice/objects/Server.js index b15a4cde8fc..526bdd4a66e 100644 --- a/js/test/Ice/objects/Server.js +++ b/js/test/Ice/objects/Server.js @@ -19,7 +19,7 @@ { return new Test.AlsoEmpty(); } - }; + } var run = function(out, id, ready) { diff --git a/js/test/Ice/proxy/Client.js b/js/test/Ice/proxy/Client.js index 07d58545989..102afbb93cf 100644 --- a/js/test/Ice/proxy/Client.js +++ b/js/test/Ice/proxy/Client.js @@ -32,7 +32,7 @@ } }; - var ref, base, prx, cl, derived, cl10, cl20, cl13, port; + var ref, base, prx, cl, derived, cl10, cl20, cl13, port, b1, b2, str, str2; var defaultProtocol = communicator.getProperties().getPropertyWithDefault("Ice.Default.Protocol", "tcp"); @@ -43,7 +43,7 @@ base = communicator.stringToProxy(ref); test(base !== null); - var b1 = communicator.stringToProxy("test"); + b1 = communicator.stringToProxy("test"); test(b1.ice_getIdentity().name === "test" && b1.ice_getIdentity().category.length === 0 && b1.ice_getAdapterId().length === 0 && b1.ice_getFacet().length === 0); b1 = communicator.stringToProxy("test "); @@ -407,7 +407,7 @@ test(id.equals(id2)); idStr = Ice.identityToString(id, Ice.ToStringMode.Compat); - test(idStr === "greek \\360\\220\\205\\252/banana \\016-\\360\\237\\215\\214\\342\\202\\254\\302\\242$") + test(idStr === "greek \\360\\220\\205\\252/banana \\016-\\360\\237\\215\\214\\342\\202\\254\\302\\242$"); id2 = Ice.stringToIdentity(idStr); test(id.equals(id2)); diff --git a/js/test/Ice/timeout/Client.js b/js/test/Ice/timeout/Client.js index 6c1cfedaed0..5e938ad5c6a 100644 --- a/js/test/Ice/timeout/Client.js +++ b/js/test/Ice/timeout/Client.js @@ -7,6 +7,11 @@ // // ********************************************************************** +/* global + isSafari : false, + isWorker : false +*/ + (function(module, require, exports) { var Ice = require("ice").Ice; diff --git a/js/test/Slice/escape/Client.js b/js/test/Slice/escape/Client.js index 0d5e0c5e23e..022e5a99dbf 100644 --- a/js/test/Slice/escape/Client.js +++ b/js/test/Slice/escape/Client.js @@ -83,7 +83,7 @@ test(p.goto === _await._var.base); test(p._if instanceof Ice.Value); test(p.internal instanceof Map); - test(p._debugger == ""); + test(p._debugger === ""); test(p._null instanceof _await.explicitPrx); }); } |