Code coverage on dev console

A quick question. We used to have a code coverage highlighted in dev console on which lines of the class are covered and not covered before.

Has salesforce removed this option or do i need to activate it somewhere?

Answer

You can get it in a pinch using the Code Coverage dropdown from an open class:

step 0

If he’s hiding… just takes a few steps after launching Developer Console:

  1. File > Open > Apex Class and select one with @isTest annotation

  2. hit Run Test on the top right

    step A

  3. go to the Tests tab, expand your test class and double click on your test run item:

    step B

  4. this exposes the Overall Code Coverage pane; now double click the name of your relevant class,

    step C

  5. see the test coverage now highlighted over the top of your code.

Attribution
Source : Link , Question Author : Prady , Answer Author : Matt and Neil

Leave a Comment