0

When you deploy an inbound change set with apex classes and their respective test classes in the change set, does the validation run tests that are in the change set or those already in the org?

So let’s say for example I am deploying from sandbox v1 to production. Production already has an apex class "class-v1" and a test class "test-v2". In sandbox v1, I have an apex class "class-v2" and its associated test class "test-v2". I add "class-v2" and "test-v2" to a change set and upload the change set to production. In production I click validate on the uploaded change set. When the validation runs, does the org look in the change set for "test-v2" or does it run the test that is currently on the org "test-v1"?

1 Answer 1

3

It runs the version of the test classes you are deploying, and will instantiate the versions of classes that you are deploying. It wouldn't make any sense to run code you're replacing to validate the new code you're prepping for deployment.

You must log in to answer this question.

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