import type { CdkTestAppOptions } from './cdk-test-app'; import type { Diagnostic, DestructiveChange, SnapshotVerificationOptions } from '../workers/common'; type RunnerOptions = Omit & { /** * Only used for testing */ readonly TESTING_compareAgainstDirectory?: string; }; export type SnapshotResult = { type: 'no-shapshot'; } | { type: 'did-compare'; diagnostics: Diagnostic[]; destructiveChanges: DestructiveChange[]; }; /** * Runner for snapshot tests. This handles orchestrating * the validation of the integration test snapshots */ export declare class IntegSnapshotRunner { private readonly options; private readonly test; constructor(options: RunnerOptions); /** * Synth the CDK app and compare the templates to the existing snapshot. * * @returns any diagnostics and any destructive changes */ testSnapshot(options?: SnapshotVerificationOptions): Promise; /** * For a given stack return all resource types that are allowed to be destroyed * as part of a stack update * * @param stackId - the stack id * @returns a list of resource types or undefined if none are found */ private getAllowedDestroyTypesForStack; /** * Find any differences between the existing and expected snapshots * * @param existing - the existing (expected) snapshot * @param actual - the new (actual) snapshot * @returns any diagnostics and any destructive changes */ private diffAssembly; /** * Reduce template to a normal form where asset references have been normalized * * This makes it possible to compare templates if all that's different between * them is the hashes of the asset values. */ private canonicalizeTemplate; } export {}; //# sourceMappingURL=snapshot-test-runner.d.ts.map