Skip to content

test: fix test freeze #3448

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

Merged
merged 5 commits into from
Jun 17, 2021
Merged

test: fix test freeze #3448

merged 5 commits into from
Jun 17, 2021

Conversation

alexander-akait
Copy link
Member

@alexander-akait alexander-akait commented Jun 16, 2021

  • This is a bugfix
  • This is a feature
  • This is a code refactor
  • This is a test update
  • This is a docs update
  • This is a metadata update

For Bugs and Features; did you add new tests?

it is tests

Motivation / Use-Case

fix freeze and throw an good error if problem happens

Breaking Changes

No

Additional Info

fixes #3399

@alexander-akait alexander-akait force-pushed the jest-do-not-freeze-on-error branch from 8ad7e7b to f14897b Compare June 16, 2021 17:26
@@ -1,124 +0,0 @@
'use strict';
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need this stupid test anymore, we have good e2e tests right now https://github.com/webpack/webpack-dev-server/blob/master/test/e2e/hot-and-live-reload.test.js

@@ -389,7 +389,7 @@ describe('webSocketServer', () => {
});
});

describe('with a bad host header', () => {
describe.skip('with a bad host header', () => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally we should remove them in favor e2e test, I will add late them

@alexander-akait
Copy link
Member Author

Should be fine now, in the next PR I will remove ports-map.js in favor simple function to get free port, so we will avoid problems with busy port and improve perf of out tests

anshumanv
anshumanv previously approved these changes Jun 16, 2021
@codecov
Copy link

codecov bot commented Jun 16, 2021

Codecov Report

Merging #3448 (e8e52e0) into master (9264812) will decrease coverage by 0.25%.
The diff coverage is 92.85%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3448      +/-   ##
==========================================
- Coverage   95.02%   94.77%   -0.26%     
==========================================
  Files          34       34              
  Lines        1346     1358      +12     
  Branches      397      401       +4     
==========================================
+ Hits         1279     1287       +8     
- Misses         62       66       +4     
  Partials        5        5              
Impacted Files Coverage Δ
lib/servers/SockJSServer.js 90.69% <77.77%> (-4.04%) ⬇️
lib/Server.js 94.83% <94.44%> (-0.19%) ⬇️
lib/servers/WebsocketServer.js 94.73% <100.00%> (-2.33%) ⬇️
lib/utils/DevServerPlugin.js 97.47% <100.00%> (+0.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update bc8328a...e8e52e0. Read the comment docs.

@alexander-akait
Copy link
Member Author

Let's merge as is and remove ports-map.js in the next PR, it will fix the whole problem with busy ports and freezing test

@alexander-akait alexander-akait merged commit 809631c into master Jun 17, 2021
@alexander-akait alexander-akait deleted the jest-do-not-freeze-on-error branch June 17, 2021 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants