Skip to content

Commit ca89c37

Browse files
Trottaddaleax
authored andcommitted
test: add debugging for callbacks in test-https-foafssl.js
The test is timing out once in a very long while on Windows CI. It is unclear where the test gets stuck, so add more debugging statements to try to locate it. Refs: #24397 PR-URL: #34603 Reviewed-By: Joyee Cheung <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent 2133b18 commit ca89c37

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

test/parallel/test-https-foafssl.js

+6-3
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ const server = https.createServer(options, common.mustCall(function(req, res) {
5656
assert.strictEqual(cert.exponent, exponent);
5757
assert.strictEqual(cert.modulus, modulus);
5858
res.writeHead(200, { 'content-type': 'text/plain' });
59-
res.end(body);
59+
res.end(body, () => { console.log('stream finished'); });
6060
console.log('sent response');
6161
}));
6262

@@ -74,8 +74,11 @@ server.listen(0, function() {
7474
const message = data.toString();
7575
const contents = message.split(CRLF + CRLF).pop();
7676
assert.strictEqual(body, contents);
77-
server.close();
78-
console.log('server closed');
77+
server.close((e) => {
78+
assert.ifError(e);
79+
console.log('server closed');
80+
});
81+
console.log('server.close() called');
7982
});
8083

8184
client.stdin.write('GET /\n\n');

0 commit comments

Comments
 (0)