-
Notifications
You must be signed in to change notification settings - Fork 3.3k
chore: remove react-scripts and jest #25383
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
Conversation
Test summaryRun details
View run in Cypress Dashboard ➡️ This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
command: yarn test | ||
working_directory: npm/webpack-preprocessor/examples/use-ts-loader | ||
- run: | ||
name: Start React app |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -7,7 +7,7 @@ | |||
"lint": "eslint --ext .js,json,.eslintrc .", | |||
"lint-changed": "node ./lib/scripts/lint-changed", | |||
"lint-fix": "npm run lint -- --fix", | |||
"test": "jest" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
npm/webpack-preprocessor/.gitignore
Outdated
@@ -4,5 +4,4 @@ node_modules/ | |||
_test-output | |||
**/cypress/videos | |||
cypress/screenshots | |||
examples/react-app/build/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might want to keep these .gitingnore paths around? Stale branches pulling in this change will likely might have these git ignore files laying around and git will suggest we check them in?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll revert! Not harming anyone and less confusion for devs.
@@ -42,12 +42,6 @@ module.exports = (on) => { | |||
} | |||
``` | |||
|
|||
## Examples |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be worth listing the system-test examples we have in place?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added a few examples back.
@@ -59,9 +59,6 @@ | |||
"mocha": "^7.1.0", | |||
"mockery": "2.1.0", | |||
"proxyquire": "2.1.3", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also drop @babel/plugin-proposal-nullish-coalescing-operator
? It was only used in use-babel
example AFAIK
Just looking through, maybe out of scope, but looks like these might not be used anymore in this module:
@fellow/eslint-plugin-coffee
@typescript-eslint/eslint-plugin
@typescript-eslint/parse
Might be a few others as well that can now rely on the root level dev deps.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll take a look later today, I love removing unused deps!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
me too 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cleaned up a few more! Could spend a week+ cleaning up all of the unused deps but I just focused on webpack-preprocessor (and batteries included).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a bunch of packages to automate removed old deps eg https://www.npmjs.com/package/depcheck. Probably worth doing at some point, should be easy enough to run a few and see what it recommends removing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Vite-dev-server's .estlintrc file includes
"globals": {
"jest": "readonly"
},
this might also be stale given there are no jest tests in vite-dev-server.
User facing changelog
na
Additional details
Remove jest from the monorepo and redundant webpack-preprocessor tests.
We already have system-tests for webpack-preprocessor that extend webpack. We should avoid having packages that install test dependencies (like react-scripts which was including jest) and utilize system-tests.
Size of node_modules before/after change:
Steps to test
na
How has the user experience changed?
na
PR Tasks
cypress-documentation
?type definitions
?