0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-24 12:10:08 +01:00
nodejs/test/parallel/test-http-import-websocket.js
Natalia Venditto a1869fa87e
http: expose websockets
PR-URL: https://github.com/nodejs/node/pull/53721
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: James M Snell <jasnell@gmail.com>
2024-07-08 15:55:43 +00:00

15 lines
398 B
JavaScript

'use strict';
require('../common');
const assert = require('assert');
const {
WebSocket: NodeHttpWebSocket,
CloseEvent: NodeHttpCloseEvent,
MessageEvent: NodeHttpMessageEvent
} = require('node:http');
// Compare with global objects
assert.strictEqual(NodeHttpWebSocket, WebSocket);
assert.strictEqual(NodeHttpCloseEvent, CloseEvent);
assert.strictEqual(NodeHttpMessageEvent, MessageEvent);