@ -22,7 +22,7 @@ function makeAssert(message) {
assert ( cp . _ handle . unrefed ( ) , true ) ;
assert ( cp . _ handle . unrefed ( ) , true ) ;
cp . ref ( ) ;
cp . ref ( ) ;
assert ( cp . _ handle . unrefed ( ) , false ) ;
assert ( cp . _ handle . unrefed ( ) , false ) ;
cp . _ handle . close ( ) ;
cp . _ handle . close ( common . mustCall ( ( ) => assert ( cp . _ handle . unrefed ( ) , true ) ) ) ;
assert ( cp . _ handle . unrefed ( ) , false ) ;
assert ( cp . _ handle . unrefed ( ) , false ) ;
}
}
@ -39,7 +39,8 @@ function makeAssert(message) {
assert ( sock4 . _ handle . unrefed ( ) , true ) ;
assert ( sock4 . _ handle . unrefed ( ) , true ) ;
sock4 . ref ( ) ;
sock4 . ref ( ) ;
assert ( sock4 . _ handle . unrefed ( ) , false ) ;
assert ( sock4 . _ handle . unrefed ( ) , false ) ;
sock4 . _ handle . close ( ) ;
sock4 . _ handle . close (
common . mustCall ( ( ) => assert ( sock4 . _ handle . unrefed ( ) , true ) ) ) ;
assert ( sock4 . _ handle . unrefed ( ) , false ) ;
assert ( sock4 . _ handle . unrefed ( ) , false ) ;
const sock6 = dgram . createSocket ( 'udp6' ) ;
const sock6 = dgram . createSocket ( 'udp6' ) ;
@ -49,7 +50,8 @@ function makeAssert(message) {
assert ( sock6 . _ handle . unrefed ( ) , true ) ;
assert ( sock6 . _ handle . unrefed ( ) , true ) ;
sock6 . ref ( ) ;
sock6 . ref ( ) ;
assert ( sock6 . _ handle . unrefed ( ) , false ) ;
assert ( sock6 . _ handle . unrefed ( ) , false ) ;
sock6 . _ handle . close ( ) ;
sock6 . _ handle . close (
common . mustCall ( ( ) => assert ( sock6 . _ handle . unrefed ( ) , true ) ) ) ;
assert ( sock6 . _ handle . unrefed ( ) , false ) ;
assert ( sock6 . _ handle . unrefed ( ) , false ) ;
}
}
@ -65,7 +67,7 @@ function makeAssert(message) {
assert ( handle . unrefed ( ) , true ) ;
assert ( handle . unrefed ( ) , true ) ;
handle . ref ( ) ;
handle . ref ( ) ;
assert ( handle . unrefed ( ) , false ) ;
assert ( handle . unrefed ( ) , false ) ;
handle . close ( ) ;
handle . close ( common . mustCall ( ( ) => assert ( handle . unrefed ( ) , true ) ) ) ;
assert ( handle . unrefed ( ) , false ) ;
assert ( handle . unrefed ( ) , false ) ;
}
}
@ -84,7 +86,8 @@ function makeAssert(message) {
server . ref ( ) ;
server . ref ( ) ;
assert ( server . _ handle . unrefed ( ) , false ) ;
assert ( server . _ handle . unrefed ( ) , false ) ;
assert ( server . _ unref , false ) ;
assert ( server . _ unref , false ) ;
server . _ handle . close ( ) ;
server . _ handle . close (
common . mustCall ( ( ) => assert ( server . _ handle . unrefed ( ) , true ) ) ) ;
assert ( server . _ handle . unrefed ( ) , false ) ;
assert ( server . _ handle . unrefed ( ) , false ) ;
}
}
@ -98,6 +101,7 @@ function makeAssert(message) {
assert ( timer . _ handle . unrefed ( ) , true ) ;
assert ( timer . _ handle . unrefed ( ) , true ) ;
timer . ref ( ) ;
timer . ref ( ) ;
assert ( timer . _ handle . unrefed ( ) , false ) ;
assert ( timer . _ handle . unrefed ( ) , false ) ;
timer . close ( ) ;
timer . _ handle . close (
common . mustCall ( ( ) => assert ( timer . _ handle . unrefed ( ) , true ) ) ) ;
assert ( timer . _ handle . unrefed ( ) , false ) ;
assert ( timer . _ handle . unrefed ( ) , false ) ;
}
}