1// Flags: --expose-internals 2'use strict'; 3require('../common'); 4 5// This test ensures that unnecessary prototypes are no longer 6// being generated by node::NewFunctionTemplate. 7 8const assert = require('assert'); 9const { internalBinding } = require('internal/test/binding'); 10[ 11 internalBinding('udp_wrap').UDP.prototype.bind6, 12 internalBinding('tcp_wrap').TCP.prototype.bind6, 13 internalBinding('udp_wrap').UDP.prototype.send6, 14 internalBinding('tcp_wrap').TCP.prototype.bind, 15 internalBinding('udp_wrap').UDP.prototype.close, 16 internalBinding('tcp_wrap').TCP.prototype.open, 17].forEach((binding, i) => { 18 assert.strictEqual('prototype' in binding, false, `Test ${i} failed`); 19}); 20