From 3bfff1438d34018ec73cbedba2bfc488adaea54a Mon Sep 17 00:00:00 2001 From: Andy Earnshaw Date: Tue, 13 Feb 2018 14:25:12 +0000 Subject: [PATCH] Disable stdin raw mode in watch quit plugin (#5028) --- packages/jest-cli/src/plugins/quit.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/jest-cli/src/plugins/quit.js b/packages/jest-cli/src/plugins/quit.js index 44e64941c4df..f3b2957141e1 100644 --- a/packages/jest-cli/src/plugins/quit.js +++ b/packages/jest-cli/src/plugins/quit.js @@ -10,6 +10,9 @@ import WatchPlugin from '../watch_plugin'; class QuitPlugin extends WatchPlugin { async showPrompt() { + if (typeof this._stdin.setRawMode === 'function') { + this._stdin.setRawMode(false); + } this._stdout.write('\n'); process.exit(0); }