Skip to content

Lesson 6: Running test giving Cannot find module error #502

Discussion options

You must be logged in to vote

@sanjayojha The typescript compiler is looking for Mocha types to run the tests. Check if you have @types/chai and @types/mocha installed in your project. You can check that from your package.json file. In any case, if any of those mentioned above package doesn't exist, do install them yarn add --dev @types/mocha @types/chai. This should solve the issue.

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
3 replies
@sanjayojha
Comment options

@dibakarsutradhar
Comment options

@sanjayojha
Comment options

Answer selected by sanjayojha
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants