UNPKG

4.41 kBTypeScriptView Raw
1import { createJestPreset as createJestPresetCore } from './config/create-jest-preset';
2import { TsJestTransformer } from './ts-jest-transformer';
3import { TsJestGlobalOptions } from './types';
4import { mocked as mockedCore } from './util/testing';
5declare module '@jest/types' {
6 namespace Config {
7 interface ConfigGlobals {
8 'ts-jest': TsJestGlobalOptions;
9 }
10 }
11}
12export declare const mocked: typeof mockedCore;
13export declare const createJestPreset: typeof createJestPresetCore;
14export declare const pathsToModuleNameMapper: (mapping: import("typescript").MapLike<string[]>, { prefix }?: {
15 prefix?: string | undefined;
16}) => {
17 [key: string]: string | string[];
18} | undefined;
19export declare const version: string;
20export declare const digest: string;
21export declare function createTransformer(baseConfig?: TsJestGlobalOptions): TsJestTransformer;
22declare const jestPreset: Pick<Partial<{
23 automock: boolean;
24 bail: number | boolean;
25 cache: boolean;
26 cacheDirectory: string;
27 clearMocks: boolean;
28 changedFilesWithAncestor: boolean;
29 changedSince: string;
30 collectCoverage: boolean;
31 collectCoverageFrom: string[];
32 collectCoverageOnlyFrom: {
33 [key: string]: boolean;
34 };
35 coverageDirectory: string;
36 coveragePathIgnorePatterns: string[];
37 coverageProvider: "babel" | "v8";
38 coverageReporters: string[];
39 coverageThreshold: {
40 global: {
41 [key: string]: number;
42 };
43 };
44 dependencyExtractor: string;
45 detectLeaks: boolean;
46 detectOpenHandles: boolean;
47 displayName: string | import("@jest/types/build/Config").DisplayName;
48 expand: boolean;
49 extraGlobals: string[];
50 filter: string;
51 findRelatedTests: boolean;
52 forceCoverageMatch: string[];
53 forceExit: boolean;
54 json: boolean;
55 globals: import("@jest/types/build/Config").ConfigGlobals;
56 globalSetup: string | null | undefined;
57 globalTeardown: string | null | undefined;
58 haste: import("@jest/types/build/Config").HasteConfig;
59 reporters: (string | import("@jest/types/build/Config").ReporterConfig)[];
60 logHeapUsage: boolean;
61 lastCommit: boolean;
62 listTests: boolean;
63 mapCoverage: boolean;
64 maxConcurrency: number;
65 maxWorkers: string | number;
66 moduleDirectories: string[];
67 moduleFileExtensions: string[];
68 moduleLoader: string;
69 moduleNameMapper: {
70 [key: string]: string | string[];
71 };
72 modulePathIgnorePatterns: string[];
73 modulePaths: string[];
74 name: string;
75 noStackTrace: boolean;
76 notify: boolean;
77 notifyMode: string;
78 onlyChanged: boolean;
79 outputFile: string;
80 passWithNoTests: boolean;
81 preprocessorIgnorePatterns: string[];
82 preset: string | null | undefined;
83 prettierPath: string | null | undefined;
84 projects: string[];
85 replname: string | null | undefined;
86 resetMocks: boolean;
87 resetModules: boolean;
88 resolver: string | null | undefined;
89 restoreMocks: boolean;
90 rootDir: string;
91 roots: string[];
92 runner: string;
93 runTestsByPath: boolean;
94 scriptPreprocessor: string;
95 setupFiles: string[];
96 setupTestFrameworkScriptFile: string;
97 setupFilesAfterEnv: string[];
98 silent: boolean;
99 skipFilter: boolean;
100 skipNodeResolution: boolean;
101 snapshotResolver: string;
102 snapshotSerializers: string[];
103 errorOnDeprecated: boolean;
104 testEnvironment: string;
105 testEnvironmentOptions: Record<string, any>;
106 testFailureExitCode: string | number;
107 testLocationInResults: boolean;
108 testMatch: string[];
109 testNamePattern: string;
110 testPathDirs: string[];
111 testPathIgnorePatterns: string[];
112 testRegex: string | string[];
113 testResultsProcessor: string;
114 testRunner: string;
115 testSequencer: string;
116 testURL: string;
117 testTimeout: number;
118 timers: "real" | "fake";
119 transform: {
120 [regex: string]: string | import("@jest/types/build/Config").TransformerConfig;
121 };
122 transformIgnorePatterns: string[];
123 watchPathIgnorePatterns: string[];
124 unmockedModulePathPatterns: string[];
125 updateSnapshot: boolean;
126 useStderr: boolean;
127 verbose?: boolean | undefined;
128 watch: boolean;
129 watchAll: boolean;
130 watchman: boolean;
131 watchPlugins: (string | [string, Record<string, any>])[];
132}>, "moduleFileExtensions" | "testMatch" | "transform">;
133export { jestPreset, };