简体   繁体   English

找不到模块“expect/build/jasmineUtils”

[英]Cannot find module 'expect/build/jasmineUtils'

Trying to execute a test suite, I found this error, that reinstalling all the jest-related dependencies doesn't fix it.尝试执行测试套件时,我发现了这个错误,即重新安装所有与 jest 相关的依赖项并不能解决问题。

Test suite failed to run

    Cannot find module 'expect/build/jasmineUtils' from 'node_modules/jest-extended/dist/utils/index.js'

    Require stack:
      node_modules/jest-extended/dist/utils/index.js
      node_modules/jest-extended/dist/matchers/toBeArrayOfSize/index.js
      node_modules/jest-extended/dist/matchers/index.js
      node_modules/jest-extended/dist/index.js

      at Resolver._throwModNotFoundError (node_modules/jest-resolve/build/resolver.js:425:11)
      at Object.<anonymous> (node_modules/jest-extended/dist/utils/index.js:8:21)
      at Object.<anonymous> (node_modules/jest-extended/dist/matchers/toBeArrayOfSize/index.js:9:14)
      at Object.<anonymous> (node_modules/jest-extended/dist/matchers/index.js:17:15)
      at Object.<anonymous> (node_modules/jest-extended/dist/index.js:3:17)

Could be related with it, seems similar: https://github.com/just-jeb/jest-marbles/issues/184可能与它有关,看起来很相似: https://github.com/just-jeb/jest-marbles/issues/184

Afterward, all were related to some problem that jest have dealing with promises in the last versions.之后,所有这些都与上一个版本中处理 promises 的一些问题有关。 Babel problems with the last version of Jest updating ReactNative 最新版本 Jest 更新 ReactNative 的 Babel 问题

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM