summaryrefslogtreecommitdiff
path: root/test/parallel/test-tls-clientcertengine-invalid-arg-type.js
blob: 811e320b07883c4877487078a8434cb7a394b236 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
'use strict';
const common = require('../common');

if (!common.hasCrypto)
  common.skip('missing crypto');

const assert = require('assert');
const tls = require('tls');

{
  assert.throws(
    () => { tls.createSecureContext({ clientCertEngine: 0 }); },
    { code: 'ERR_INVALID_ARG_TYPE',
      message: / Received type number \(0\)/ });
}