blob: 417b21804a407589c87be02674723b5cf2a674d4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
'use strict';
/*
* Issue: https://github.com/nodejs/node/issues/3655
* Test checks if we get exception instead of runtime error
*/
const common = require('../common');
if (!common.hasCrypto) {
common.skip('missing crypto');
return;
}
const assert = require('assert');
const TlsSocket = require('tls').TLSSocket;
const EventEmitter = require('events').EventEmitter;
assert.throws(
() => { new TlsSocket(new EventEmitter()); },
/^TypeError: this\.stream\.pause is not a function/
);
|