mirror of
https://github.com/nodejs/node.git
synced 2026-11-26 21:58:26 -05:00
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:
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();
|
||||
|
||||
Reference in new issue
Block a user