+ Start a Discussion
Syed Abid ShahSyed Abid Shah 

I am facing challenges with code coverage

Hi Folks,

Recently we developed a functionality in staging instance to delete multiple cases at a time however business approved to move this to Production. when we tried to deploye same from UAT instance to Prodcution its throwing error 'code coverage is not 75%'. can you please let us know how best we can build up to cover 75% coverage to make smotth deployment.
Details below:
We got deployment Error during Deploying “Delete Cases ” custom button in production .
Organization’s code coverage is 54% and few triggers have 0% code coverage in production. We need minimum  75%  organization code coverage to deploy the code into production.

Raj VakatiRaj Vakati
Hi Syed  ,

Please use this links 


karthikeyan perumalkarthikeyan perumal

Run you all test class in production  once. using below option. 

Setup->Apex class-consider below image: 
click on " Run All Tests" its referesh your code coverage. 

User-added image


in your deployment package if there is any trigger- trigger must have atleast 1% of code coverage. 
so you have to write test class for your triggers also. 


check all test class must have above 75% code coverage. so that your org coverage will increase. if your class doest not have above 75 % your org also will fail to get 75% and above. 

hope this wil help you.

if everything is clear above issue will gone automatically.