+ Start a Discussion

Problem with Code Coverage and Deploy



I'm trying to deploy an Apex app i developed, and for that i covered 78% of my code with tests (trying to get to 100% :D).

But every time i try to deploy, an error message appears:


Apex Class    My Class    No testMethods found in the selected Apex code for the package


And that's not true, because if i click on My Class link, it shows that this class has 100% of coverage.


Is this happening because instead of testing my classes on the same apex class, i'm using separated classes for each test?

(like, for MyClassController.cls i have a MyClassControllerTest.cls that is a private class with @isTest).

Kevin BromerKevin Bromer

Having seperate test classes wouldn't be causing your problems, we use that model in a variety of internal projects. Are you certain the test class made it into the package along with the actual production class?