function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Code Coverage mismatch

After running the test class when i open the class file, the code coverage is 100%. But the total number of lines of the class is 954. its showing only 182.

User-added image

when i open Developer consiole and check the same class it is showing only 45%.

User-added image

Can anyone help me what is the issue with this.?
This is a known problem and MVPs like Jeff and Wes have good posts about the same. Here are links for reference:

I think one way is to clear the Test execution history from "Setup > Develop > Apex test execution", and try again. Running all tests might help getting more accurate coverage after cleaning the stale results.