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
ColaCola 

Error Deploying Workflow Rule with Change Sets

I'm trying to deploy a workflow rule with a change set from my Sandbox to Production and I get the following error:

Code Coverage Failure
Your organization's code coverage is 74%. You need at least 75% coverage to complete this deployment.

I checked around online and found that people recommended running all tests in Developer Console in my production environment to see which test class is failing and when I do that I see that the overall code coverage is 75%.

Any idea on what I can do to have to deployment succeed?

Thanks,
Marc
Best Answer chosen by Cola
AshlekhAshlekh
Hi,

You have to work on Test Classes and increase the code coverage.

IF it helps you than please mark it as a solution and ENJOY APEX

All Answers

AshlekhAshlekh
Hi,

You have to work on Test Classes and increase the code coverage.

IF it helps you than please mark it as a solution and ENJOY APEX
This was selected as the best answer
Shri RajShri Raj
I wouldnt recommend this always but Since its only 74%, I would give a try deploying again. It usually works out. If it keeps on displaying the same error then you need to fix the test classes and increase the code coverage. 

For all the Code coverage in Production, You need to have over 75% of the Test Code Coverage. Thats the issue. 
AshwaniAshwani
If you are pushing Workflows only then you don't need to check test coverage in sandbox. There can be chance that your production environment don't have enough coverage. If it is you have to increase test coverage in sandbox and push those classes in production.