SnapshotResolver.d.ts 745 B

12345678910111213141516
  1. /**
  2. * Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved.
  3. *
  4. * This source code is licensed under the MIT license found in the
  5. * LICENSE file in the root directory of this source tree.
  6. */
  7. import type { Config } from '@jest/types';
  8. export declare type SnapshotResolver = {
  9. testPathForConsistencyCheck: string;
  10. resolveSnapshotPath(testPath: Config.Path, extension?: string): Config.Path;
  11. resolveTestPath(snapshotPath: Config.Path, extension?: string): Config.Path;
  12. };
  13. export declare const EXTENSION = "snap";
  14. export declare const DOT_EXTENSION: string;
  15. export declare const isSnapshotPath: (path: string) => boolean;
  16. export declare const buildSnapshotResolver: (config: Config.ProjectConfig) => SnapshotResolver;