summaryrefslogtreecommitdiff
path: root/js/test/Ice/proxy/Client.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/test/Ice/proxy/Client.js')
-rw-r--r--js/test/Ice/proxy/Client.js37
1 files changed, 36 insertions, 1 deletions
diff --git a/js/test/Ice/proxy/Client.js b/js/test/Ice/proxy/Client.js
index 38bdd4d2310..d31c1f9b1b1 100644
--- a/js/test/Ice/proxy/Client.js
+++ b/js/test/Ice/proxy/Client.js
@@ -10,6 +10,7 @@
(function(module, require, exports)
{
var Ice = require("ice").Ice;
+ var IceSSL = require("ice").IceSSL;
var Test = require("Test").Test;
var Promise = Ice.Promise;
@@ -916,7 +917,7 @@
}
var p1, pstr;
-
+
// Legal TCP endpoint expressed as opaque endpoint
p1 = communicator.stringToProxy("test -e 1.1:opaque -e 1.0 -t 1 -v CTEyNy4wLjAuMeouAAAQJwAAAA==");
pstr = communicator.proxyToString(p1);
@@ -1019,6 +1020,40 @@
).then(
function()
{
+ var p = communicator.stringToProxy("test:default -p 12010");
+ if(defaultProtocol === "tcp")
+ {
+ test(p.ice_getEndpoints()[0].getInfo() instanceof Ice.TCPEndpointInfo);
+ }
+ else if(defaultProtocol === "ws")
+ {
+ test(p.ice_getEndpoints()[0].getInfo() instanceof Ice.WSEndpointInfo);
+ }
+ else if(defaultProtocol === "wss")
+ {
+ test(p.ice_getEndpoints()[0].getInfo() instanceof IceSSL.WSSEndpointInfo);
+ }
+ return p.ice_getConnection()
+ }
+ ).then(
+ function(con)
+ {
+ if(defaultProtocol === "tcp")
+ {
+ test(con.getInfo() instanceof Ice.TCPConnectionInfo);
+ }
+ else if(defaultProtocol === "ws")
+ {
+ test(con.getInfo() instanceof Ice.WSConnectionInfo);
+ }
+ else if(defaultProtocol === "wss")
+ {
+ test(con.getInfo() instanceof IceSSL.WSSConnectionInfo);
+ }
+ }
+ ).then(
+ function()
+ {
out.writeLine("ok");
var derived = Test.MyDerivedClassPrx.uncheckedCast(communicator.stringToProxy("test:default -p 12010"));
return derived.shutdown();