Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 72d7159

Browse filesBrowse files
santigimenoMylesBorins
authored andcommitted
test: fix flaky repl-timeout-throw
Don't disconnect the child until all exceptions are thrown. Fixes: #18659 PR-URL: #18692 Fixes: #18659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
1 parent 3cfb313 commit 72d7159
Copy full SHA for 72d7159

File tree

Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Open diff view settings
Collapse file

‎test/sequential/test-repl-timeout-throw.js‎

Copy file name to clipboardExpand all lines: test/sequential/test-repl-timeout-throw.js
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
'use strict';
2-
const common = require('../common');
2+
require('../common');
33
const assert = require('assert');
44

55
const spawn = require('child_process').spawn;
@@ -13,6 +13,8 @@ child.stdout.setEncoding('utf8');
1313
child.stdout.on('data', function(c) {
1414
process.stdout.write(c);
1515
stdout += c;
16+
if (stdout.includes('> THROW 2'))
17+
child.stdin.end();
1618
});
1719

1820
child.stdin.write = function(original) {
@@ -46,8 +48,6 @@ child.stdout.once('data', function() {
4648
' });\n' +
4749
' });\n' +
4850
'});"";\n');
49-
50-
setTimeout(child.stdin.end.bind(child.stdin), common.platformTimeout(200));
5151
}
5252
});
5353

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.