node/test/addons-napi
Anatoli Papirovski f2dd17bde9
timers: allow Immediates to be unrefed
Refactor Immediates handling to allow for them to be unrefed, similar
to setTimeout, but without extra handles.

Document the new `immediate.ref()` and `immediate.unref()` methods.

Add SetImmediateUnref on the C++ side.

Backport-PR-URL: https://github.com/nodejs/node/pull/19006
PR-URL: https://github.com/nodejs/node/pull/18139
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
2018-02-26 18:39:45 -05:00
..
1_hello_world n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
2_function_arguments n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
3_callbacks n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
4_object_factory n-api: add optional string length parameters 2017-09-18 17:47:34 -04:00
5_function_factory n-api: add optional string length parameters 2017-09-18 17:47:34 -04:00
6_object_wrap n-api: add optional string length parameters 2017-09-18 17:47:34 -04:00
7_factory_wrap tools: add cpplint rule for NULL usage 2017-12-12 03:27:59 -05:00
8_passing_wrapped n-api: add optional string length parameters 2017-09-18 17:47:34 -04:00
test_array n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
test_async n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_buffer test: remove literals that obscure assert messages 2018-01-08 02:21:01 -05:00
test_callback_scope test: remove unnecessary timer 2018-02-21 14:20:23 -05:00
test_constructor n-api: remove extra reference from test 2018-02-21 10:19:20 -05:00
test_conversions n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_dataview n-api: throw RangeError in napi_create_dataview() with invalid range 2018-01-24 07:47:27 -06:00
test_env_sharing n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_error test: remove ambiguous error messages from test_error 2018-01-09 04:32:36 -05:00
test_exception test: show pending exception error in napi tests 2018-02-21 10:19:01 -05:00
test_fatal n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_function n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_general test: improve error message output 2018-02-21 10:19:28 -05:00
test_handle_scope doc: use American spellings per style guide 2017-12-12 03:28:19 -05:00
test_make_callback test: properly tag anonymous namespaces 2018-02-21 14:20:04 -05:00
test_make_callback_recurse test: properly tag anonymous namespaces 2018-02-21 14:20:04 -05:00
test_number doc: use American spellings per style guide 2017-12-12 03:28:19 -05:00
test_object n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
test_promise test: add unhandled rejection guard 2018-01-08 02:20:01 -05:00
test_properties n-api: fix warning about size_t compare with int 2017-09-24 10:47:27 -04:00
test_reference n-api: refactor napi_addon_register_func 2017-09-14 15:02:10 -04:00
test_string n-api: add check for large strings 2017-09-29 17:44:41 -04:00
test_symbol test,benchmark,doc: enable dot-notation rule 2018-02-21 18:12:26 -05:00
test_typedarray test: fixed typos in napi test 2018-01-30 10:23:56 -06:00
test_uv_loop timers: allow Immediates to be unrefed 2018-02-26 18:39:45 -05:00
test_warning n-api: use module name macro 2017-10-15 16:00:29 -07:00
.gitignore
common.h n-api: add code parameter to error helpers 2017-07-13 15:05:19 -04:00
testcfg.py n-api: remove n-api module loading flag 2017-09-19 19:06:44 -04:00