mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-12 22:28:59 +02:00
Automatic update from web-platform-testsRemove the "W3C WebSocket API" prefix from websockets/ tests (#13478) This prefix doesn't add any useful information, and isn't used in all tests in this directory. Noticed because of the screen real estate it takes up in a view like this: https://wpt.fyi/results/websockets/Send-binary-65K-arraybuffer.any.html In the directory, this command was run, on macOS: git grep -lF 'W3C WebSocket API - ' | xargs sed -i '' 's/W3C WebSocket API - //g' -- wpt-commits: 1e747acc90ecdbd23ef3348a144b77696cced55b wpt-pr: 13478
13 lines
486 B
JavaScript
13 lines
486 B
JavaScript
// META: script=websocket.sub.js
|
|
|
|
var test = async_test("Create Secure WebSocket - Close the Connection - close(1005) - see '7.1.5. The WebSocket Connection Close Code' in http://www.ietf.org/rfc/rfc6455.txt");
|
|
|
|
var wsocket = CreateWebSocket(true, false, false);
|
|
var isOpenCalled = false;
|
|
|
|
wsocket.addEventListener('open', test.step_func(function(evt) {
|
|
assert_throws("INVALID_ACCESS_ERR", function() {
|
|
wsocket.close(1005, "1005 - reserved code")
|
|
});
|
|
test.done();
|
|
}), true);
|