@flxbl-io/sfp
Version:
sfp is a CLI tool to help you manage your Salesforce projects in an artifact centric model
64 lines (63 loc) • 2.45 kB
TypeScript
import { PackageInstallationResult } from '../../core/package/packageInstallers/PackageInstallationResult';
import { Org } from '@salesforce/core';
import ValidateResult from './ValidateResult';
import SfpPackage from '../../core/package/SfpPackage';
import { PostDeployHook } from '../deploy/PostDeployHook';
import { PreDeployHook } from '../deploy/PreDeployHook';
export declare enum ValidateAgainst {
PROVIDED_ORG = "PROVIDED_ORG",
PRECREATED_POOL = "PRECREATED_POOL"
}
export declare enum ValidationMode {
INDIVIDUAL = "individual",
FAST_FEEDBACK = "fastfeedback",
THOROUGH = "thorough",
FASTFEEDBACK_LIMITED_BY_RELEASE_CONFIG = "ff-release-config",
THOROUGH_LIMITED_BY_RELEASE_CONFIG = "thorough-release-config"
}
export interface ValidateProps {
installExternalDependencies?: boolean;
validateAgainst: ValidateAgainst;
validationMode: ValidationMode;
releaseConfigPaths?: string[];
coverageThreshold: number;
logsGroupSymbol: string[];
targetOrg?: string;
hubOrg?: Org;
pools?: string[];
shapeFile?: string;
isDeleteScratchOrg?: boolean;
keys?: string;
branch?: string;
baseBranch?: string;
diffcheck?: boolean;
disableArtifactCommit?: boolean;
orgInfo?: boolean;
disableSourcePackageOverride?: boolean;
disableParallelTestExecution?: boolean;
}
export default class ValidateImpl implements PostDeployHook, PreDeployHook {
private props;
private logger;
private orgAsSFPOrg;
private impactedPackagesAsPerBranch;
constructor(props: ValidateProps);
exec(): Promise<ValidateResult>;
private computePackagesChangedAgainstBaseBranch;
private printArtifactVersions;
private installPackageDependencies;
private handleScratchOrgStatus;
private deployPackages;
private buildImpactedPackages;
private fetchScratchOrgFromPool;
private getCurrentRemainingNumberOfOrgsInPoolAndReport;
preDeployPackage(sfpPackage: SfpPackage, targetUsername: string, deployedPackages?: SfpPackage[], devhubUserName?: string): Promise<{
isToFailDeployment: boolean;
message?: string;
}>;
postDeployPackage(sfpPackage: SfpPackage, packageInstallationResult: PackageInstallationResult, targetUsername: string, deployedPackages?: SfpPackage[], devhubUserName?: string): Promise<{
isToFailDeployment: boolean;
message?: string;
}>;
private updateOrgWithArtifact;
}