Skip to content

Commit 575982b

Browse files
authored
Forbid Haste in Jest (#11647)
1 parent fa7a97f commit 575982b

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

scripts/jest/config.source.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
'use strict';
22

33
module.exports = {
4+
haste: {
5+
hasteImplModulePath: require.resolve('./noHaste.js'),
6+
},
47
modulePathIgnorePatterns: [
58
'<rootDir>/scripts/rollup/shims/',
69
'<rootDir>/scripts/bench/',

scripts/jest/noHaste.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
'use strict';
2+
3+
module.exports = {
4+
getHasteName() {
5+
// We never want Haste.
6+
return null;
7+
},
8+
};

0 commit comments

Comments
 (0)