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
krish99krish99 

Increase The Test Class

HI,

 

         Generally how can we increase the test class code coverage, Is there any procedure to increase the test class code coverage...???

SFDC-NOOBSFDC-NOOB

Do you have specific code you are trying to cover?  Did you call all methods?

Abhi_TripathiAbhi_Tripathi

just check it out which line is not covered in the test class using eclipse , mostly it happens with exceptions or error messages so you can create a scenario where user gets an error message in the test class, using this you can increase your code coverage

 

You can check out this post for test classes

 

http://abhithetechknight.blogspot.in/2013/10/salesforce-test-class-basics.html