blob: 1e1c82225309b4cedda3548506ad00609b66d5da (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
'use strict';
const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
const assert = require('assert');
const tls = require('tls');
['fhqwhgads', 42, {}, []].forEach((testValue) => {
assert.throws(
() => { tls.createServer({ SNICallback: testValue }); },
{ code: 'ERR_INVALID_ARG_TYPE', message: /\boptions\.SNICallback\b/ }
);
});
|