diff options
author | Anna Henningsen <anna@addaleax.net> | 2017-11-18 14:54:06 +0100 |
---|---|---|
committer | Anna Henningsen <anna@addaleax.net> | 2017-11-21 12:50:06 +0100 |
commit | 5d7f5c16b3ae49325b7bb0a79eaba3e945585ced (patch) | |
tree | acca78da096b0ac5f645330399a7b0d2ef87d412 /test/async-hooks | |
parent | 85f3e319c40dfe5b89d1f31a69ac8f3d9cf291b2 (diff) | |
download | android-node-v8-5d7f5c16b3ae49325b7bb0a79eaba3e945585ced.tar.gz android-node-v8-5d7f5c16b3ae49325b7bb0a79eaba3e945585ced.tar.bz2 android-node-v8-5d7f5c16b3ae49325b7bb0a79eaba3e945585ced.zip |
src: remove async_hooks destroy timer handle
PR-URL: https://github.com/nodejs/node/pull/17117
Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'test/async-hooks')
-rw-r--r-- | test/async-hooks/test-signalwrap.js | 14 | ||||
-rw-r--r-- | test/async-hooks/test-tcpwrap.js | 6 |
2 files changed, 12 insertions, 8 deletions
diff --git a/test/async-hooks/test-signalwrap.js b/test/async-hooks/test-signalwrap.js index ff7d08bc12..fa975ff017 100644 --- a/test/async-hooks/test-signalwrap.js +++ b/test/async-hooks/test-signalwrap.js @@ -66,12 +66,14 @@ function onsigusr2() { } function onsigusr2Again() { - checkInvocations( - signal1, { init: 1, before: 2, after: 2, destroy: 1 }, - 'signal1: when second SIGUSR2 handler is called'); - checkInvocations( - signal2, { init: 1, before: 1 }, - 'signal2: when second SIGUSR2 handler is called'); + setImmediate(() => { + checkInvocations( + signal1, { init: 1, before: 2, after: 2, destroy: 1 }, + 'signal1: when second SIGUSR2 handler is called'); + checkInvocations( + signal2, { init: 1, before: 1 }, + 'signal2: when second SIGUSR2 handler is called'); + }); } process.on('exit', onexit); diff --git a/test/async-hooks/test-tcpwrap.js b/test/async-hooks/test-tcpwrap.js index 1f4fc6af0d..4693e730bf 100644 --- a/test/async-hooks/test-tcpwrap.js +++ b/test/async-hooks/test-tcpwrap.js @@ -128,8 +128,10 @@ function onconnection(c) { function onserverClosed() { checkInvocations(tcp1, { init: 1, before: 1, after: 1, destroy: 1 }, 'tcp1 when server is closed'); - checkInvocations(tcp2, { init: 1, before: 2, after: 2, destroy: 1 }, - 'tcp2 when server is closed'); + setImmediate(() => { + checkInvocations(tcp2, { init: 1, before: 2, after: 2, destroy: 1 }, + 'tcp2 after server is closed'); + }); checkInvocations(tcp3, { init: 1, before: 1, after: 1 }, 'tcp3 synchronously when server is closed'); tick(2, () => { |