Skip to content

Commit 8719aff

Browse files
fix: add workerIdleMemoryLimit to ValidConfig (#13105)
1 parent 6b6d52c commit 8719aff

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

packages/jest-config/src/ValidConfig.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,7 @@ const initialOptions: Config.InitialOptions = {
187187
],
188188
],
189189
watchman: true,
190+
workerIdleMemoryLimit: multipleValidOptions(0.2, '50%'),
190191
};
191192

192193
export default initialOptions;

packages/jest-types/src/Config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ export type InitialOptions = Partial<{
327327
watchAll: boolean;
328328
watchman: boolean;
329329
watchPlugins: Array<string | [string, Record<string, unknown>]>;
330-
workerIdleMemoryLimit: number;
330+
workerIdleMemoryLimit: number | string;
331331
}>;
332332

333333
export type SnapshotUpdateState = 'all' | 'new' | 'none';
@@ -574,6 +574,6 @@ export type Argv = Arguments<
574574
watchAll: boolean;
575575
watchman: boolean;
576576
watchPathIgnorePatterns: Array<string>;
577-
workerIdleMemoryLimit: number;
577+
workerIdleMemoryLimit: number | string;
578578
}>
579579
>;

0 commit comments

Comments
 (0)