1

fairly new and have been working out of my sandbox. i have created a couple triggers and i want to deploy to production. problem is my code coverage is only 17%. I have a bunch of testclass in my sandbox that I would love to deactivate. everything i read talks about doing this from eclipse ide. I don't have eclipse and I only work through my sandbox and code with developer console.

Can anyone tell me of a way to deactivate classes without using eclipse IDE? is there a way to do this from the user interface or developer console?

any help would be greatly appreciated.

Wick

3 Answers 3

2

Did you try deploying to Production? The 75% is in the org you are moving TO not from. Your overall code coverage in Sandbox isn't important. You just need to review what the coverage is for the particular Trigger you want to move to Production.

0

Yes, you can deactivate your triggers in the sandbox and deploy them to production via a change set.

If you haven't already done this, you'll need to create a deployment connection between your sandbox and production. You then create an outbound change set, add the triggers to it, and then upload the change set. On the production side, you open the inbound change set and click "Deploy"

There's more info on changesets available here

4
  • thanks but this looks like instructions to deploy to production. I understand how to deploy but I'm trying to deactivate old test classes before deploying to increase my code coverage rate to 75%.
    – WickWack
    Jun 20, 2014 at 19:20
  • I know of no way to deactivate them in production. The "standard" answer I've found is "deactivate in sandbox, then deploy to production". Annoying, but that's the current state of Salesforce.
    – Jagular
    Jun 20, 2014 at 19:25
  • Here's one discussion of deactivating triggers: developer.salesforce.com/forums?id=906F00000008vKyIAI
    – Jagular
    Jun 20, 2014 at 19:32
  • I appreciate your help jagular but I think I'm not making myself clear. I want to deactivate old classes that I have in my sandbox. the thought behind this is it will help drive up my code coverage percentage. after i deactivate old test classes THEN i would deploy to production if my coverage is at or above 75%. again i appreciate your help.
    – WickWack
    Jun 20, 2014 at 19:35
0

I don't believe you can deactivate classes, you could delete them or comment them out but not deactivate them. The closest thing would be to create a rule in custom settings that would let you turn them on or off but that wouldn't help you with code coverage.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .