You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems when I just run npx jest everything runs just fine, all the tests pass in record time.
As soon as I try to pass the coverage flag over I get many failures ie: npx jest --coverage.
If I run the test suite that is failing in isolation everything seems to run fine ie: npx jest src/app.module.spec.ts --coverage --collectCoverageFrom=src/app.module.ts
If I remove the collectCoverageFrom flag then it proceeds to fail again ie: npx jest src/app.module.spec.ts --coverage
It seems as if many of the dependencies that are mocked out in a test are not being mocked. If I isolate the coverage collection it seems to be fine, but then it seems that when all the files are gathered for coverage it's causing issues. Is it trying to run the code crawling through the AST instead of through the spec implementation that mocks things out?
The text was updated successfully, but these errors were encountered:
It seems when I just run
npx jest
everything runs just fine, all the tests pass in record time.As soon as I try to pass the coverage flag over I get many failures ie:
npx jest --coverage
.If I run the test suite that is failing in isolation everything seems to run fine ie:
npx jest src/app.module.spec.ts --coverage --collectCoverageFrom=src/app.module.ts
If I remove the
collectCoverageFrom
flag then it proceeds to fail again ie:npx jest src/app.module.spec.ts --coverage
It seems as if many of the dependencies that are mocked out in a test are not being mocked. If I isolate the coverage collection it seems to be fine, but then it seems that when all the files are gathered for coverage it's causing issues. Is it trying to run the code crawling through the AST instead of through the spec implementation that mocks things out?
The text was updated successfully, but these errors were encountered: