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:
57 files changed
+246
-286
No files matched your search
@@ -42,13 +42,13 @@ const options = {
|
||||
rejectUnauthorized: false
|
||||
};
|
||||
|
||||
const server = https.createServer(options, function(req, res) {
|
||||
const server = https.createServer(options, common.mustCallAtLeast((req, res) => {
|
||||
assert.strictEqual(req.socket.authorized, false); // not a client cert
|
||||
assert.strictEqual(req.socket.authorizationError,
|
||||
'DEPTH_ZERO_SELF_SIGNED_CERT');
|
||||
res.writeHead(200);
|
||||
res.end('OK');
|
||||
});
|
||||
}));
|
||||
|
||||
server.listen(0, options.host, common.mustCall(function() {
|
||||
options.port = this.address().port;
|
||||
|
||||
Reference in new issue
Block a user