Skip to content

the 6.4.3 have an issue of Cannot find module 'lodash/isEqualWith'  #598

Closed
@arvinxx

Description

@arvinxx
  • @testing-library/jest-dom version: 6.4.3
  • node version: 20.9.0
  • jest (or vitest) version: [email protected]
  • npm (or yarn) version: 9.2.0

Relevant code or config:

we have tests run correctly in 6.4.2 , but failed in 6.4.3

What you did:

npm run test

What happened:

Error: Cannot find module '/Users/arvinxx/CodeProjects/LobeHub/lobe-chat/node_modules/.pnpm/@[email protected][email protected]_@[email protected]_@[email protected][email protected][email protected]_/node_modules/lodash/isEqualWith' imported from /Users/arvinxx/CodeProjects/LobeHub/lobe-chat/node_modules/.pnpm/@[email protected][email protected]_@[email protected]_@[email protected][email protected][email protected]_/node_modules/@testing-library/jest-dom/dist/index.mjs
Did you mean to import [email protected]/node_modules/lodash/isEqualWith.js?

you can check the test ci here: https://github.com/lobehub/lobe-chat/actions/runs/8935588080/job/24544431213

Reproduction:

https://github.com/lobehub/lobe-chat/tree/reproduction/jest-dom-6.4.3

Problem description:

it shows the lodash/isEqualWith can not be found

Suggested solution:

I think the issue caused by the change of this: v6.4.2...v6.4.3#diff-26a76dbc98134c4a252853d189242826b97531753657672282afdd05d608dfac

it should be the import isEqualWith from 'lodash/isEqualWith.js'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions