Clover report: NCLOC is greater than LOC

I am using Clover to collect code coverage report for a perl project. I observed that the LOC is always less than NCLOC.  From my understanding of LOC, it is the total lines of code and NCLOC is non-comment lines of code. 

 

Is this expected or a problem in report generation ? 

 

 <coverage generated="1502211630" clover="1.01" >
3 <project timestamp="1502211630" name="Devel::Cover::Report::Clover">
4 <metrics packages="27" elements="16" coveredelements="16" statements="12" coveredstatements="12" compl exity="0" files="227" loc="22295" ncloc="58665" classes="237" conditionals="0" coveredconditionals="0" methods ="4" coveredmethods="4"/>

 

Let me know if you need more details.  

1 answer

This widget could not be displayed.

Hey, 

From my understanding of LOC, it is the total lines of code and NCLOC is non-comment lines of code. 

That's right.  LOC is total lines of code and NLOC is non-comment lines of code and NLOC  should be lower or equal LOC.

However,  if you use Clover for a perl project, the problem might be in a report covnerter, since Clover is not able to gather coverage from perl projects. 

Thanks Grzegorz. I am using Devel::Cover::Clover::Report package for generating the report.  I will try and look from that side. 

Suggest an answer

Log in or Sign up to answer
Atlassian Summit 2018

Meet the community IRL

Atlassian Summit is an excellent opportunity for in-person support, training, and networking.

Learn more
Community showcase
Posted yesterday in New to Jira

Are you planning to trial, or are currently trialling Jira Software? - We want to talk to you!

Hello! I'm Rayen, a product manager at Atlassian. My team and I are working hard to improve the trial experience for Jira Software Cloud. We are interested in   talking to 20 people planning t...

78 views 1 0
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you