testdouble / testdouble/testdouble.js
Module not found: Error: Can't resolve 'module' in 'node_modules/testdouble/lib'
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.4k
- Forks
- 140
- Avg merge
- 22h
- Merged PRs (30d)
- 1
Description
I have an angular app, and testdouble in my devDependencies of my package file. When I try to run my angular test suite, I am getting:
./node_modules/testdouble/lib/can-register-loader.js:1:15-32 - Error: Module not found: Error: Can't resolve 'module' in '/path/to/project/node_modules/testdouble/lib'
literally require('module'); is breaking...
I am wondering why this isn't an internal dependency of testdouble?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with node_modules/testdouble/lib/can-register-loader.js and reproduce the failure in the reported Angular test suite. Check how testdouble declares and loads the module dependency, then verify the fix against the same module-resolution error. Done means the Angular tests no longer fail on require('module').
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, javascript
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100