My team would like to gradually replace change set deployment model with unlocked packages. I did some experiments and found out that installing package in an org is somehow like running partial deployment using change sets.

As far as I know, some errors can only be found out with full validation. (Don't know if it is called integration test).

Do people still run full validation in Production before installing a new version of package into Production?

  • By validation do you mean running apex test classes ? Jun 22, 2020 at 8:25
  • Yes. Like this "sfdx force:apex:test:run" Jun 22, 2020 at 8:32

1 Answer 1


So far tests are not required for Unlocked Packages, however starting Winter '21, they will be required and run when you create a package version as explained here.

You can currently validate the tests of your package using the --codecoverage flag during the package version creation (sfdx force:package:version:create).

However, these tests are run during creation, not installation. As you said, you'll have to run sfdx force:apex:test:run manually to be sure that all tests are valid.

  • The one of Winter '21 new policy is 75% coverage of the unlocked package itself instead of the whole org I guess. My real concern is that some test classes outside of the package may not pass after a new package creation. And this will not be detected if one does not specify "sfdx force:apex:test:run" before the creation. Jun 22, 2020 at 9:02
  • Got it, but running sfdx force:apex:test:run manually is the only option you have so far. Jun 22, 2020 at 10:04
  • 1
    You can still reply on the Chatter feed I posted and ask for this feature though. Jun 22, 2020 at 10:05

You must log in to answer this question.

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