test: ensure assertions are reached on more tests

PR-URL: https://github.com/nodejs/node/pull/60759
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
This commit is contained in:
Antoine du Hamel authored and RafaelGSS committed 2026-01-13 10:04:26 -03:00
1 parent 585e200b40
commit 79d48f9441
57 files changed
+246 -286

No files matched your search

@@ -139,7 +139,7 @@ test(function serverResponseTimeoutWithPipeline(cb) {
process.on('exit', () => {
assert.strictEqual(caughtTimeout, '/2');
});
const server = https.createServer(serverOptions, (req, res) => {
const server = https.createServer(serverOptions, common.mustCallAtLeast((req, res) => {
if (req.url === '/2')
secReceived = true;
if (req.url === '/1') {
@@ -150,7 +150,7 @@ test(function serverResponseTimeoutWithPipeline(cb) {
caughtTimeout += req.url;
});
assert.ok(s instanceof http.OutgoingMessage);
});
}));
server.on('timeout', common.mustCall((socket) => {
if (secReceived) {
socket.destroy();