I have a managed package having various Apex classes with test classes.

Now when I click on code coverage of a Apex class it shows nothing.

Is there any way by which we can see color covered code of a Apex class.

Thanks and Regards

Ashish agarwal

2 Answers 2


Howeve this has no fix till date: you can see here https://success.salesforce.com/issues_view?id=a1p30000000SzHiAAK.

But there is a work around:

If your class name a myClass1 and page is myPage. Duplicate and rename to myClass1.

  • Now write a test class for myClass1 (which is exact copy of myClass). By this you will be able to see code coverage of ismyClass1.

  • When you done with this code coverage change the Apex class name and its constructor(s) to myClass and run its test.

Also here is a question already posted regarding this issue: Can't see Apex Class Code coverage in packaging org using code coverage link


enter image description here

Open your developer console and in that you will see Tests in bottom and once you click the class name in right corner it will open to display red and blue lines for only unmanaged package.I think from winter 14 i see this is the only way to check lines not covered and marked as red or blue .

For managed package also the code coverage is shown but red and blue lines wont be seen as for managed code the code is not visible .

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .