From 2e3a4cfa760a066f99748057dc406a0bc38921fb Mon Sep 17 00:00:00 2001 From: Michael Dawson Date: Fri, 13 Oct 2017 12:59:04 -0400 Subject: [PATCH] n-api: use module name macro Update tests to use module name macro PR-URL: https://github.com/nodejs/node/pull/16185 Reviewed-By: Gabriel Schulhof Reviewed-By: James M Snell Reviewed-By: Colin Ihrig --- test/addons-napi/test_warning/test_warning.c | 2 +- test/addons-napi/test_warning/test_warning2.c | 2 +- test/addons/callback-scope/binding.cc | 2 +- test/addons/dlopen-ping-pong/binding.cc | 2 +- test/addons/node-module-version/binding.cc | 2 +- test/addons/openssl-binding/binding.cc | 2 +- test/addons/zlib-binding/binding.cc | 2 +- test/gc/binding.cc | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/test/addons-napi/test_warning/test_warning.c b/test/addons-napi/test_warning/test_warning.c index a152ff8481..d0821be1f2 100644 --- a/test/addons-napi/test_warning/test_warning.c +++ b/test/addons-napi/test_warning/test_warning.c @@ -8,4 +8,4 @@ napi_value Init(napi_env env, napi_value exports) { return result; } -NAPI_MODULE(test_warning, Init) +NAPI_MODULE(NODE_GYP_MODULE_NAME, Init) diff --git a/test/addons-napi/test_warning/test_warning2.c b/test/addons-napi/test_warning/test_warning2.c index b35f9071c0..3c8ee9db01 100644 --- a/test/addons-napi/test_warning/test_warning2.c +++ b/test/addons-napi/test_warning/test_warning2.c @@ -8,4 +8,4 @@ napi_value Init(napi_env env, napi_value exports) { return result; } -NAPI_MODULE(test_warning2, Init) +NAPI_MODULE(NODE_GYP_MODULE_NAME, Init) diff --git a/test/addons/callback-scope/binding.cc b/test/addons/callback-scope/binding.cc index 22105360fb..f03d8a20d5 100644 --- a/test/addons/callback-scope/binding.cc +++ b/test/addons/callback-scope/binding.cc @@ -68,4 +68,4 @@ void Initialize(v8::Local exports) { } // namespace -NODE_MODULE(binding, Initialize) +NODE_MODULE(NODE_GYP_MODULE_NAME, Initialize) diff --git a/test/addons/dlopen-ping-pong/binding.cc b/test/addons/dlopen-ping-pong/binding.cc index 14a817a13e..b35db4e708 100644 --- a/test/addons/dlopen-ping-pong/binding.cc +++ b/test/addons/dlopen-ping-pong/binding.cc @@ -41,7 +41,7 @@ void init(Local exports) { NODE_SET_METHOD(exports, "ping", Ping); } -NODE_MODULE(binding, init) +NODE_MODULE(NODE_GYP_MODULE_NAME, init) } // anonymous namespace diff --git a/test/addons/node-module-version/binding.cc b/test/addons/node-module-version/binding.cc index f46f0eb2c6..3baafe23a4 100644 --- a/test/addons/node-module-version/binding.cc +++ b/test/addons/node-module-version/binding.cc @@ -12,4 +12,4 @@ inline void Initialize(v8::Local exports, } -NODE_MODULE_CONTEXT_AWARE(binding, Initialize) +NODE_MODULE_CONTEXT_AWARE(NODE_GYP_MODULE_NAME, Initialize) diff --git a/test/addons/openssl-binding/binding.cc b/test/addons/openssl-binding/binding.cc index 582a94478d..fa40b3346a 100644 --- a/test/addons/openssl-binding/binding.cc +++ b/test/addons/openssl-binding/binding.cc @@ -29,4 +29,4 @@ inline void Initialize(v8::Local exports, } // anonymous namespace -NODE_MODULE_CONTEXT_AWARE(binding, Initialize) +NODE_MODULE_CONTEXT_AWARE(NODE_GYP_MODULE_NAME, Initialize) diff --git a/test/addons/zlib-binding/binding.cc b/test/addons/zlib-binding/binding.cc index 262f90bf02..a9a8c14306 100644 --- a/test/addons/zlib-binding/binding.cc +++ b/test/addons/zlib-binding/binding.cc @@ -52,4 +52,4 @@ inline void Initialize(v8::Local exports, } // anonymous namespace -NODE_MODULE_CONTEXT_AWARE(binding, Initialize) +NODE_MODULE_CONTEXT_AWARE(NODE_GYP_MODULE_NAME, Initialize) diff --git a/test/gc/binding.cc b/test/gc/binding.cc index 197bb6a40a..8bde3b8505 100644 --- a/test/gc/binding.cc +++ b/test/gc/binding.cc @@ -77,4 +77,4 @@ inline void Initialize(v8::Local exports, } // anonymous namespace -NODE_MODULE_CONTEXT_AWARE(binding, Initialize) +NODE_MODULE_CONTEXT_AWARE(NODE_GYP_MODULE_NAME, Initialize)