Skip to content

Commit 26951bd

Browse files
authored
chore(jest-types): correct return type of shouldRunTestSuite fo… (#9753)
1 parent d010f0e commit 26951bd

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
### Features
44

55
### Fixes
6+
- `[@jest/watcher]` Correct return type of `shouldRunTestSuite` for `JestHookEmitter` ([#9753](https://github.com/facebook/jest/pull/9753))
67

78
### Chore & Maintenance
89

packages/jest-watcher/src/types.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ export type JestHookSubscriber = {
3636
export type JestHookEmitter = {
3737
onFileChange: (fs: JestHookExposedFS) => void;
3838
onTestRunComplete: (results: AggregatedResult) => void;
39-
shouldRunTestSuite: (testSuiteInfo: TestSuiteInfo) => Promise<boolean>;
39+
shouldRunTestSuite: (
40+
testSuiteInfo: TestSuiteInfo,
41+
) => Promise<boolean> | boolean;
4042
};
4143

4244
export type UsageData = {

0 commit comments

Comments
 (0)