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
SennahSennah 

Can not save to dev. org.

Hi all,

 

I have a big problem here:

Eclipse is telling me that line converage is too low and prevents saving. But this is my dev. org. and it is my understanding that there is no line coverage needed - or is this different with force.com sites dev. orgs?

Although I am a fan of "test first" this is somehow bothering. Any help appreciated ;)

 

In case support is reading this: My org. ID is 00DA0000000HPxx

 

Best,

Hannes

 

 

Best Answer chosen by Admin (Salesforce Developers) 
JonPJonP

"Save to Server" in the IDE uses the Metadata API deploy() call.  There's no backdoor; all the rules of deploy are enforced.

 

If you are certain this is a Developer Edition organization, and not Force.com Free Edition (which is a free production organization that includes a sandbox for development), then you should contact support directly.

All Answers

WesNolte__cWesNolte__c

Hey

 

If you are trying to deploy to the Org then you need the code coverage. If possible try using 'Save to server' as this does not require any coverage.

 

Cheers,

Wes

SennahSennah

Hi wez,

 

I am only trying to "save to server" from within Eclipse...

Far away from deploying ;)

 

Hannes

JonPJonP

"Save to Server" in the IDE uses the Metadata API deploy() call.  There's no backdoor; all the rules of deploy are enforced.

 

If you are certain this is a Developer Edition organization, and not Force.com Free Edition (which is a free production organization that includes a sandbox for development), then you should contact support directly.

This was selected as the best answer
SennahSennah

Hi Jon,

 

thanks  for that. I wasn't aware of the fact that this is  a free trial. I thought it was a diffent type of developer organization.

 

Best,

Hannes

WesNolte__cWesNolte__c

Hey

 

It's seems I can learn something from this thread too, just to clarify,

 

- If I deploy to server and my code coverage is not adequate, the deployment cannot be completed?

- If I save to server and don't have the code coverage you're saying it will also fail? 

 

On the second point I have pushed quite large chunks of code entirely untested into developer and sandbox Orgs, and I've done this more than a few times (I know I know, I should be testing as a I go along;). Perhaps my first statement is incorrect?

 

Wes

SennahSennah
Maybe your tests were covering the new code without your notice...
WesNolte__cWesNolte__c
Ah, but I had no tests. No even one.
JonPJonP

Code coverage requirements only apply to production organizations (e.g. Enterprise Edition, Unlimited Edition, and Force.com Free Edition).

 

They do not apply to sandboxes or Developer Edition organizations, so that you have a place to write and test your code.

 

Because of the differences between the two, and the fact that Save to Server and Deploy to Server use the same Metadata API deploy() verb, we strongly advise against creating Force.com projects in the IDE against production organizations.  The recommended process is to create your projects against a sandbox, edit your files and use Save to Server, then use Deploy to Server to migrate the changes to production.

 

The IDE won't prevent you from creating a project against production, but every time you Save to Server it will run all test methods and reject the save if any tests fail or if org-wide code coverage isn't met--correctly, mind you, since you shouldn't be able to change production in either of these cases--which is not an ideal way to work.

 

I believe there may be some metadata files you can save to production without all tests being run, but certainly for any Apex class or trigger deployment what I've described above holds true.

 

Jon

 

 

WesNolte__cWesNolte__c

Knowledge++

 

Thanks Jon, much appreciated.