Fix for cannot 'TypeError: Cannot read property' when Dependabot submits a PR to upgrade a Jest Module
GitHub’s Dependabot is a great tool to help keep your dependencies up to date, and most of the time the PR it generates just merges without a problem. However, sometimes there are issues with other related dependencies. This was the case with a recent PR to update jest-circus to 28.x. The PR failed with the error TypeError: Cannot read property ’enableGlobally’ of undefined at jestAdapter (node_modules/jest-circus/build/legacy-code-todo-rewrite/jestAdapter.js:39:25) at TestScheduler.scheduleTests (node_modules/@jest/core/build/TestScheduler.js:333:13) at runJest (node_modules/@jest/core/build/runJest....