Skip to content

Commit

Permalink
Added regenerator-runtime for async jest tests
Browse files Browse the repository at this point in the history
  • Loading branch information
akiran committed Feb 9, 2024
1 parent ec32089 commit cf31307
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,8 @@
"webpack": "^4.21.0",
"webpack-cli": "^3.1.2",
"webpack-dev-server": "^3.1.9",
"why-did-you-update": "^0.1.1"
"why-did-you-update": "^0.1.1",
"regenerator-runtime": "^0.14.1"
},
"dependencies": {
"classnames": "^2.2.5",
Expand Down
1 change: 1 addition & 0 deletions test-setup.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import "@testing-library/jest-dom/extend-expect";
import "regenerator-runtime/runtime";

//Fix for "matchMedia not present, legacy browsers require a polyfill jest" error
window.matchMedia =
Expand Down

0 comments on commit cf31307

Please sign in to comment.