node/test/js-native-api
legendecas f14fa1bbca
node-api: generalize finalizer second pass callback
Generalize the finalizer's second pass callback to make it
cancellable and simplify the code around the second pass callback.

With this change, it is determined that Reference::Finalize or
RefBase::Finalize are called once, either from the env's shutdown,
or from the env's second pass callback.

All existing node-api js tests should pass without a touch. The
js_native_api cctest is no longer applicable with this change,
just removing it.

PR-URL: https://github.com/nodejs/node/pull/44141
Refs: https://github.com/nodejs/node/issues/44071
Reviewed-By: Michael Dawson <midawson@redhat.com>
2022-12-20 01:44:42 +08:00
..
2_function_arguments
3_callbacks
4_object_factory
5_function_factory
6_object_wrap node-api: generalize finalizer second pass callback 2022-12-20 01:44:42 +08:00
7_factory_wrap
8_passing_wrapped
test_array
test_bigint
test_constructor
test_conversions
test_dataview
test_date
test_error
test_exception
test_function
test_general node-api: handle no support for external buffers 2022-11-09 13:30:43 -05:00
test_handle_scope
test_instance_data
test_new_target
test_number
test_object src: fix napi_check_object_type_tag() 2022-07-14 15:22:46 -04:00
test_promise
test_properties
test_reference node-api: emit uncaught-exception on unhandled tsfn callbacks 2022-05-27 13:32:08 -04:00
test_reference_double_free node-api: fix immediate napi_remove_wrap test 2022-11-18 09:31:25 +00:00
test_string
test_symbol
test_typedarray
.gitignore
common.c
common.h
entry_point.c
testcfg.py