0

Alright, so I think this is a Salesforce bug but wanted to check with the community to see if I'm just overlooking something.

I'm trying to debug some code in production so I added a couple of system.debug lines to an existing controller and then uploaded it to Production. When I tried to deploy, it gave me a code coverage error, stating that coverage is only 51%.

When I run all of my tests in Production, code coverage is 84%. When I run all of my tests in the Sandbox, code coverage is 84%. The sandbox was refreshed yesterday and I'm only adding system.debug lines to an existing controller, so there's no way I don't have the coverage needed to deploy.

Has anyone ever ran into this before? This has to be a bug, right?

  • do you see any test method failure? – Himanshu Apr 10 '16 at 19:30
  • No, no failures at all. It just states code coverage error and that's all. – sfdcJameson Apr 10 '16 at 19:31
  • can you try to run specific test instead of run all test. – Himanshu Apr 10 '16 at 19:48
0

Would suggest installing the following package which will give you a detailed code coverage report. https://appexchange.salesforce.com/listingDetail?listingId=a0N3000000DXzlpEAD

Compare the report in both orgs to check for differences.

You very well might have code that is not being covered in an org but is not causing an assertion error. Hard to guess why with isolating the differences..

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.