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
Abhijeet Purohit01Abhijeet Purohit01 

Problem during deploying.

While deploying a class with its test class( coverage 100%) I got error msges. The errors are in the test classes which have already been deployed into the production. It said the code coverage for 4 test classes which are already in production is less than 75%. I made the necessary changes and made the code coverage more than 75% for all the 4 test classes and tried to deploy the classes. But again am getting the same error messages.

 

How to solve this problem?

 

 

Please help me.

Manoj_onlineManoj_online

Deploy your test classes first and then try deploy your new class.

rocwilcoxrocwilcox

How are you deploying?  Ant? Eclipse "save to sever"? Eclipse "deploy to server"?

Sometimes when you get into this situation where you've made significant changes to your classes and test classes you'll need to "deploy to server" and not just save.

Deploy considers all the changes at once, where as "save to server" is a bit more sequential, and thus you can get into a catch-22 situation. (needing A deploy so B can deploy, but B depends on A...)

 

 

 

Abhijeet Purohit01Abhijeet Purohit01

I was trying to deploy one test class at a time so it had become a kind of loop wherein a test class failed to validate coz of error in someother test class which is already in production. So I deployed all the 4 test classes together. And it worked. I had thought that I cannot deploy unrelated test classes at a time. But it did work.

 

Thanks for all the help. Thank you very much.