Skip to content

Commit

Permalink
Barf a little more elegantly
Browse files Browse the repository at this point in the history
  • Loading branch information
fbennett committed Mar 19, 2019
1 parent ffbdcb9 commit b7afb80
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions tests/runtests.js
Expand Up @@ -16,10 +16,11 @@ process.stdin.setRawMode(true);
process.stdin.resume();
process.stdin.setEncoding( 'utf8' );
process.stdin.on('data', function( key ){
// ctrl-c ( end of text )
if ( key === '\u0003' ) {
process.exit();
}
// ctrl-c ( end of text )
if ( key === '\u0003' ) {
console.log("\n");
process.exit();
}
});

/* Configuration */
Expand Down Expand Up @@ -780,6 +781,7 @@ function runFixtures() {
});
mocha.on('close', (code) => {
if (!options.watch) {
console.log("\n");
process.exit();
}
});
Expand Down

0 comments on commit b7afb80

Please sign in to comment.