Closed zachnewburgh closed 5 years ago
It's not enabled by default but you can have it print to console if you add 'text'
to the root jest.config.js
's coverageReporters
option. Feel free to make the change in your repo.
Closing this issue for now. Please reopen if you have any other issues.
You're a hero. Thanks, @FrozenPandaz!
It's not enabled by default but you can have it print to console if you add
'text'
to the rootjest.config.js
'scoverageReporters
option. Feel free to make the change in your repo.Closing this issue for now. Please reopen if you have any other issues.
Hi @FrozenPandaz ,
I have a nx project with Angular + Jest, how do I obtain a global (unique) coverage summaries? I'm currently using the Jest's 'text-summary'
as coverageReporters
but it promps as many abstracts as libraries... Any idea?
Thanks in advance. Regards, Romain.
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.
Prerequisites
Expected Behavior
ng test
runs the test suites and prints the code coverage report to the console.Current Behavior
ng test
runs the test suites.Failure Information (for bugs)
On a newly-created workspace, neither
ng test
norng test --code-coverage
prints out the code coverage report to the console. Further, Jest commands cannot be appended tong test
to remediate, nor canng test
be easily substituted forjest
.Additionally, adding
codeCoverage: true
to the app's test options configuration in the angular.json does not resolve the issue. The issue also persists when addingcollectCoverageFrom: ['**/*.{js,jsx}', '!**/node_modules/**', '!**/vendor/**']
to the jest.config.jsmodule.exports
.Steps to Reproduce
Please provide detailed steps for reproducing the issue.
yarn create nx-workspace myworkspace
);cd myworkspace
);ng test
);Context
I used the instructions listed on the Getting Started page. Attempted with workspaces that included Angular, React, and Angular and React applications.
To confirm that this wasn't an issue with the latest version of Jest, I followed Jest's Getting Started instructions and ran
jest --coverage
, which successfully printed the code coverage report.Failure Logs
N/A
Other
Thanks, in advance, for your help :)