diff options
Diffstat (limited to 'testing/web-platform/tests/websockets/Create-verify-url-set-non-default-port.htm')
-rw-r--r-- | testing/web-platform/tests/websockets/Create-verify-url-set-non-default-port.htm | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/testing/web-platform/tests/websockets/Create-verify-url-set-non-default-port.htm b/testing/web-platform/tests/websockets/Create-verify-url-set-non-default-port.htm new file mode 100644 index 000000000..181794df9 --- /dev/null +++ b/testing/web-platform/tests/websockets/Create-verify-url-set-non-default-port.htm @@ -0,0 +1,19 @@ +<!DOCTYPE html> +<html> +<head> + <title>W3C WebSocket API - Create WebSocket - wsocket.url is set correctly - non default port</title> + <script type="text/javascript" src="/resources/testharness.js"></script> + <script type="text/javascript" src="/resources/testharnessreport.js"></script> + <script type="text/javascript" src="websocket.sub.js"></script> +</head> +<body> + <div id="log"></div> + <script type="text/javascript"> + test(function () { + var urlNonDefaultPort = "ws://" + __SERVER__NAME + ":" + __NEW__PORT + "/" + __PATH; + var wsocket = new WebSocket(urlNonDefaultPort); + assert_equals(wsocket.url, urlNonDefaultPort, "wsocket.url is set correctly"); + }, "W3C WebSocket API - Create WebSocket - wsocket.url should be set correctly"); + </script> +</body> +</html> |