File tree Expand file tree Collapse file tree 4 files changed +9
-0
lines changed Expand file tree Collapse file tree 4 files changed +9
-0
lines changed Original file line number Diff line number Diff line change 5
5
### Fixes
6
6
7
7
- ` [jest-haste-map] ` Add missing ` @types/graceful-fs ` dependency ([ #9913 ] ( https://github.com/facebook/jest/pull/9913 ) )
8
+ - ` [jest-runner] ` Correctly serialize ` Set ` passed to worker ([ #9915 ] ( https://github.com/facebook/jest/pull/9915 ) )
8
9
9
10
### Chore & Maintenance
10
11
Original file line number Diff line number Diff line change @@ -158,6 +158,9 @@ class TestRunner {
158
158
changedFiles :
159
159
this . _context . changedFiles &&
160
160
Array . from ( this . _context . changedFiles ) ,
161
+ sourcesRelatedToTestsInChangedFiles :
162
+ this . _context . sourcesRelatedToTestsInChangedFiles &&
163
+ Array . from ( this . _context . sourcesRelatedToTestsInChangedFiles ) ,
161
164
} ,
162
165
globalConfig : this . _globalConfig ,
163
166
path : test . path ,
Original file line number Diff line number Diff line change @@ -89,6 +89,9 @@ export async function worker({
89
89
context && {
90
90
...context ,
91
91
changedFiles : context . changedFiles && new Set ( context . changedFiles ) ,
92
+ sourcesRelatedToTestsInChangedFiles :
93
+ context . sourcesRelatedToTestsInChangedFiles &&
94
+ new Set ( context . sourcesRelatedToTestsInChangedFiles ) ,
92
95
} ,
93
96
) ;
94
97
} catch ( error ) {
Original file line number Diff line number Diff line change @@ -49,13 +49,15 @@ export type TestRunnerOptions = {
49
49
serial : boolean ;
50
50
} ;
51
51
52
+ // make sure all props here are present in the type below it as well
52
53
export type TestRunnerContext = {
53
54
changedFiles ?: Set < Config . Path > ;
54
55
sourcesRelatedToTestsInChangedFiles ?: Set < Config . Path > ;
55
56
} ;
56
57
57
58
export type TestRunnerSerializedContext = {
58
59
changedFiles ?: Array < Config . Path > ;
60
+ sourcesRelatedToTestsInChangedFiles ?: Array < Config . Path > ;
59
61
} ;
60
62
61
63
// TODO: Should live in `@jest/core` or `jest-watcher`
You can’t perform that action at this time.
0 commit comments