node/test/addons-napi
Gabriel Schulhof 70b2e169b4
test: fix up N-API error test
Replace assert.throws() with an explicit try/catch in order to catch
the thrown value and be able to compare it strictly to an expected
value.

Re: https://github.com/nodejs/node/pull/20428#issuecomment-386160684

PR-URL: https://github.com/nodejs/node/pull/20487
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
2018-05-08 18:26:16 -07:00
..
1_hello_world n-api,test: make methods static 2018-05-04 11:49:32 -04:00
2_function_arguments n-api,test: make methods static 2018-05-04 11:49:32 -04:00
3_callbacks n-api,test: make methods static 2018-05-04 11:49:32 -04:00
4_object_factory n-api,test: make methods static 2018-05-04 11:49:32 -04:00
5_function_factory n-api,test: make methods static 2018-05-04 11:49:32 -04:00
6_object_wrap
7_factory_wrap tools: add cpplint rule for NULL usage 2017-12-01 07:45:05 +01:00
8_passing_wrapped n-api: back up env before finalize 2018-04-03 09:37:11 -04:00
test_array n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_async n-api: add napi_fatal_exception 2018-03-20 15:48:14 -04:00
test_buffer n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_callback_scope test: remove unnecessary timer 2018-02-14 10:24:51 -05:00
test_constructor n-api,test: remove superfluous persistent 2018-05-04 11:51:12 -04:00
test_conversions n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_dataview n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_env_sharing n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_error test: fix up N-API error test 2018-05-08 18:26:16 -07:00
test_exception n-api: ensure in-module exceptions are propagated 2018-03-27 14:08:24 -04:00
test_fatal n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_fatal_exception n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_function n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_general n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_handle_scope n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_make_callback n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_make_callback_recurse n-api: add missing exception checking 2018-03-16 19:01:24 -04:00
test_new_target n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_number n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_object n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_promise n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_properties n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_reference n-api,test: make method static 2018-05-04 11:51:12 -04:00
test_string n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_symbol n-api: remove unused Test function 2018-05-04 11:51:12 -04:00
test_typedarray n-api,test: make methods static 2018-05-04 11:49:32 -04:00
test_uv_loop Revert "build,test: make building addon tests less fragile" 2018-01-25 08:18:24 +11:00
.gitignore
common.h
testcfg.py