Skip to content

Latest commit

 

History

History
21 lines (15 loc) · 623 Bytes

jest.md

File metadata and controls

21 lines (15 loc) · 623 Bytes

Using Jest with Enzyme

If you are using Jest 0.9+ with enzyme and using Jest's automocking feature, you will need to mark react and enzyme to be unmocked in your package.json:

/* package.json */

"jest": {
  "unmockedModulePathPatterns": [
    "node_modules/react/",
    "node_modules/enzyme/"
  ]
}

If you are using a previous version of Jest together with npm3, you may need to unmock more modules.

Example Projects