File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
packages/react-scripts/scripts Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,18 @@ if (!process.env.CI && argv.indexOf('--coverage') < 0) {
2626 argv . push ( '--watch' ) ;
2727}
2828
29+ // A temporary hack to clear terminal correctly.
30+ // You can remove this after updating to Jest 18 when it's out.
31+ // https://github.com/facebook/jest/pull/2230
32+ var realWrite = process . stdout . write ;
33+ var CLEAR = process . platform === 'win32' ? '\x1Bc' : '\x1B[2J\x1B[3J\x1B[H' ;
34+ process . stdout . write = function ( chunk , encoding , callback ) {
35+ if ( chunk === '\x1B[2J\x1B[H' ) {
36+ chunk = CLEAR ;
37+ }
38+ return realWrite . call ( this , chunk , encoding , callback ) ;
39+ } ;
40+
2941// @remove -on-eject-begin
3042// This is not necessary after eject because we embed config into package.json.
3143const createJestConfig = require ( '../utils/createJestConfig' ) ;
You can’t perform that action at this time.
0 commit comments