Skip to content
This repository was archived by the owner on Mar 18, 2024. It is now read-only.

Commit 00d7b64

Browse files
feat(install): Specify testLevel for a not optimized source package validating (#1434)
Co-authored-by: Azlam <[email protected]>
1 parent 2f07ff4 commit 00d7b64

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

packages/core/src/package/packageInstallers/InstallPackage.ts

+9
Original file line numberDiff line numberDiff line change
@@ -468,6 +468,15 @@ export abstract class InstallPackage {
468468
deploymentOptions.testLevel = TestLevel.RunLocalTests;
469469
}
470470
}
471+
}
472+
// #Issue 1417
473+
// Handle the use-cases of a not optimized source package validating
474+
else if (this.sfpPackage.packageType == PackageType.Source && this.sfpPackage.isApexFound && this.options.isInstallingForValidation && !optimizeDeployment ) {
475+
if (skipTest) {
476+
deploymentOptions.testLevel = TestLevel.RunNoTests;
477+
} else {
478+
deploymentOptions.testLevel = TestLevel.RunLocalTests;
479+
}
471480
} else {
472481
if (orgDetails.isSandbox) {
473482
deploymentOptions.testLevel = TestLevel.RunNoTests;

0 commit comments

Comments
 (0)