Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does yellow highlighting mean in istanbul?

I just started using istanbul test coverage module for mocha. When I look at the report some code is yellow highlighted. I could not find in the docs what this means?

like image 314
bier hier Avatar asked Mar 01 '17 23:03

bier hier


People also ask

What does it mean when someone Highlighter is yellow?

Yellow The most common of the highlighters used — unless you’re a girl, of course — highlighting something in yellow is often misinterpreted as your understanding that the highlighted item is more important than what is not highlighted, but not as important as something highlighted in a less commonly used colour.

Why are some lines of code highlighted red in Istanbul?

Not executed lines, or pieces of code, will be highlighted in red. This has been verified for Istanbul v0.4.0, I'm not sure if this still applies for subsequent versions, but being that library is based on solid theoretic principles, behavior shouldn't change too much for newer versions. Pink: statements not covered. Orange: functions not covered.

What does the yellow highlight in the coverage report mean?

Yellow highlighting in the coverage report means that the branch has not been covered. Branch coverage display only kicks in if one or more but not all branches have been taken (if none of the branches were taken the statement coverage will show you that unambiguously)

What is the meaning of the Orange highlighter on the ballot?

Some think that items highlighted in orange are being put off until the end of October. Others just assume it was the only highlighter at hand. Actual meaning: These items will be done either at sunrise or sunset on a day near the end of October. Known as the “royal colour,” this colour was used to highlight things that were of extreme importance.


1 Answers

Yellow highlighting in the coverage report means that the branch has not been covered.

From a GitHub issue:

  • Pink: statement not covered
  • Orange: function not covered
  • Yellow: branch not covered
  • [I] and [E] in front of if-else statements: if or else not covered respectively
  • Branch coverage display only kicks in if one or more but not all branches have been taken (if none of the branches were taken the statement coverage will show you that unambiguously)

Here's an SO post that breaks down what each of those mean in a little more depth: How do I read an Istanbul Coverage Report?

like image 167
mzmm56 Avatar answered Oct 09 '22 18:10

mzmm56