Your code needs to have 75% code coverage before you can move it into Production environment.
So basically - 1. You need to create a Test Class in your staging environment that provides more than 75% code coverage for your code (Trigger/Class) 2. Move the Test Class first into the Production environment using any migration tool like Eclipse IDE or Force.com Migration Tool 3. Finally move your code into Production
If your code is not having adequate code coverage (75% or more), then the deployment will fail.
Thanks AR
If you found the reply useful that solved your problem then please mark it as best answer.
I agree with Vish, Salesforce doesnt allow us to create apex and VF in production..so you can not paste the code directly there..and here comes the testcoverage in picture...There is no need to code coverage if we could have paste the code directly in production..
So to port everything there you need to go wuth changesets and we should have minimum 75% code coverage overall..then only it will allow you to port the changes to poroduction..
P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.
Hi All, I agree with all but my production lot of issues(Example: Managed mackages test classes failures).That's why i am asking.Plese give me there is any suggestion with out deployment directly add my vf page and apex class and test class(100% covered) into production..
Your code needs to have 75% code coverage before you can move it into Production environment.
So basically -
1. You need to create a Test Class in your staging environment that provides more than 75% code coverage for your code (Trigger/Class)
2. Move the Test Class first into the Production environment using any migration tool like Eclipse IDE or Force.com Migration Tool
3. Finally move your code into Production
If your code is not having adequate code coverage (75% or more), then the deployment will fail.
Thanks
AR
If you found the reply useful that solved your problem then please mark it as best answer.
We can not directly paste code into production. Salesforce does not allow us to make apex & visualforce changes directly in production.
Thanks,
Vishal
I agree with Vish, Salesforce doesnt allow us to create apex and VF in production..so you can not paste the code directly there..and here comes the testcoverage in picture...There is no need to code coverage if we could have paste the code directly in production..
So to port everything there you need to go wuth changesets and we should have minimum 75% code coverage overall..then only it will allow you to port the changes to poroduction..
P.S. If my answer helps you to solve your problem please mark it as best answer. It will help other to find best answer.
Thanks,
Sandeep
Salesforce Certified Developer
I agree with all but my production lot of issues(Example: Managed mackages test classes failures).That's why i am asking.Plese give me there is any suggestion with out deployment directly add my vf page and apex class and test class(100% covered) into production..
Thanks...
You cannot deploy to production unless all the test methods pass and overall code coverage is above 75 %.
Thanks,
Vishal Shinde