mirror of https://github.com/lukechilds/node.git
Browse Source
This commit completes code coverage for dgram's Socket#ref() and Socket#unref() methods. PR-URL: https://github.com/nodejs/node/pull/11240 Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>v6
2 changed files with 21 additions and 4 deletions
@ -1,7 +1,14 @@ |
|||
'use strict'; |
|||
require('../common'); |
|||
const common = require('../common'); |
|||
const dgram = require('dgram'); |
|||
|
|||
// should not hang, see #1282
|
|||
dgram.createSocket('udp4'); |
|||
dgram.createSocket('udp6'); |
|||
|
|||
{ |
|||
// Test the case of ref()'ing a socket with no handle.
|
|||
const s = dgram.createSocket('udp4'); |
|||
|
|||
s.close(common.mustCall(() => s.ref())); |
|||
} |
|||
|
Loading…
Reference in new issue