我正在使用create-react-app。means that you are trying to import a file which Jest cannot parse, e.g. it's not plain JavaScript.import '@testing-library/jest-dom';import Adapt
<anonymous>":function(module,exports,require,__dirname,__filename,global,jest){export * from '._transformAndBuildScript (node_modules/jest-runtime/build/ScriptTransformer.js:289:17)
我正在使用jest在一个库上运行一些测试,在我升级了一个现在导出到es6的库之后,我得到了错误"Cannot use import statement on a module“,在升级之前,测试运行得很好我正在使用的jest.config.js文件: module.exports = { transform: {
'^.+\\.tsx$': 't