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
Bhushan Singh 13Bhushan Singh 13 

If i have 10 classes 9 classes has 75 % code coverage , 1 class has no code coverage ,while deploy all the classes will be deploy or not

If i have 10 classes  9 classes has 75 % code coverage , 1 class  has no code coverage ,while  deploy  all the classes will be deploy or not , or only 9 classes will deploy 1 class will fail.
please answer my question.
Hi Bhushan,

you can deploy apex class with out maintaining any code coverage but that is not good way(i am guessing).

means you can deploy
Amit Chaudhary 8Amit Chaudhary 8
Please check below post for same

Coverage is based on the total number of code lines in the organization. Adding or deleting lines of code changes the coverage percentage. For example, let's say an organization has 50 lines of code covered by test methods. If you add a trigger that has 50 lines of code not covered by tests, the code coverage percentage drops from 100% to 50%. The trigger increases the total code lines in the organization from 50 to 100, of which only 50 are covered by tests

For example, if you have 10000 lines of code in your organization, and one class is 9000 lines of code with 100% coverage, then the remaining 1000 lines of code require no coverage at all, and may be at 0% (except for the 1% trigger rule).

NOTE:- In short your overall code covarege should be 75%. 75% should be calculated with all classes.