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
I wrote unit tests for the following calculateStatus function that needs refactoring. I am very certain that most of it is covered (as can be seen by the green 1x - 36x on the left side of the report) and yet they are highlighted in red and the coverage stats seems to be incorrect.
If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can yarn install and yarn test.
Unfortunately, I cannot reproduce this. This exact function and its unit test was taken from an old project (with the same jest and typescript config and the coverage was working fine in that one). I have used --no-cache and yet the problem still persists for this particular project.
What is the expected behavior?
The lines that were covered will NOT be highlighted and will be treated as covered.
Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.
Do you want to request a feature or report a bug?
I am reporting a bug.
What is the current behavior?
I wrote unit tests for the following
calculateStatus
function that needs refactoring. I am very certain that most of it is covered (as can be seen by the green 1x - 36x on the left side of the report) and yet they are highlighted in red and the coverage stats seems to be incorrect.If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can
yarn install
andyarn test
.Unfortunately, I cannot reproduce this. This exact function and its unit test was taken from an old project (with the same jest and typescript config and the coverage was working fine in that one). I have used
--no-cache
and yet the problem still persists for this particular project.What is the expected behavior?
The lines that were covered will NOT be highlighted and will be treated as covered.
Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.
jest v20.0.4
yarn v0.27.5
typescript v2.4.2
Jest config
The text was updated successfully, but these errors were encountered: