Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: fix todo #3653

Merged
merged 1 commit into from
Aug 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,52 @@ Array [

exports[`web socket communication should work and close web socket client connection when web socket server closed ("ws"): page errors 1`] = `Array []`;

exports[`web socket communication should work and reconnect when the connection is lost ("sockjs"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] Disconnected!",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] App hot update...",
"[HMR] Checking for updates on the server...",
"Failed to load resource: the server responded with a status of 404 (Not Found)",
"[HMR] Cannot find update. Need to do a full reload!",
"[HMR] (Probably because of restarting the webpack-dev-server)",
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
]
`;

exports[`web socket communication should work and reconnect when the connection is lost ("sockjs"): page errors 1`] = `Array []`;

exports[`web socket communication should work and reconnect when the connection is lost ("ws"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] Disconnected!",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] App hot update...",
"[HMR] Checking for updates on the server...",
"Failed to load resource: the server responded with a status of 404 (Not Found)",
"[HMR] Cannot find update. Need to do a full reload!",
"[HMR] (Probably because of restarting the webpack-dev-server)",
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
]
`;

exports[`web socket communication should work and reconnect when the connection is lost ("ws"): page errors 1`] = `Array []`;

exports[`web socket communication should work and terminate client that is not alive ("sockjs"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,52 @@ Array [

exports[`web socket communication should work and close web socket client connection when web socket server closed ("ws"): page errors 1`] = `Array []`;

exports[`web socket communication should work and reconnect when the connection is lost ("sockjs"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] Disconnected!",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] App hot update...",
"[HMR] Checking for updates on the server...",
"Failed to load resource: the server responded with a status of 404 (Not Found)",
"[HMR] Cannot find update. Need to do a full reload!",
"[HMR] (Probably because of restarting the webpack-dev-server)",
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
]
`;

exports[`web socket communication should work and reconnect when the connection is lost ("sockjs"): page errors 1`] = `Array []`;

exports[`web socket communication should work and reconnect when the connection is lost ("ws"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] Disconnected!",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
"[webpack-dev-server] App hot update...",
"[HMR] Checking for updates on the server...",
"Failed to load resource: the server responded with a status of 404 (Not Found)",
"[HMR] Cannot find update. Need to do a full reload!",
"[HMR] (Probably because of restarting the webpack-dev-server)",
"[HMR] Waiting for update signal from WDS...",
"Hey.",
"[webpack-dev-server] Hot Module Replacement enabled.",
"[webpack-dev-server] Live Reloading enabled.",
]
`;

exports[`web socket communication should work and reconnect when the connection is lost ("ws"): page errors 1`] = `Array []`;

exports[`web socket communication should work and terminate client that is not alive ("sockjs"): console messages 1`] = `
Array [
"[HMR] Waiting for update signal from WDS...",
Expand Down
3 changes: 1 addition & 2 deletions test/e2e/web-socket-communication.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,7 @@ describe("web socket communication", () => {
await server.stop();
});

// TODO uncomment after fix regression in webpack
it.skip(`should work and reconnect when the connection is lost ("${websocketServer}")`, async () => {
it(`should work and reconnect when the connection is lost ("${websocketServer}")`, async () => {
WebsocketServer.heartbeatInterval = 100;

const compiler = webpack(config);
Expand Down