node-api: add nested object wrap and napi_ref test#57981
node-api: add nested object wrap and napi_ref test#57981nodejs-github-bot merged 2 commits intonodejs:mainfrom
Conversation
|
Review requested:
|
8fdaaaa to
a5aa845
Compare
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled.
a5aa845 to
161b8e3
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #57981 +/- ##
==========================================
- Coverage 90.27% 90.27% -0.01%
==========================================
Files 630 630
Lines 186165 186158 -7
Branches 36485 36475 -10
==========================================
- Hits 168064 168049 -15
- Misses 10974 10979 +5
- Partials 7127 7130 +3 🚀 New features to boost your workflow:
|
|
@legendecas , in regards to the PR #57861, do we ever have a situation when a |
This comment was marked as duplicate.
This comment was marked as duplicate.
I think Putting a single finalizer into the queue twice is a bug. Do you have a minimum test to reproduce it? |
This comment was marked as outdated.
This comment was marked as outdated.
@legendecas , no, I do not have a repro. I am just trying to understand if the PR #57861 has issues or not. Currently based on your answers, I tend to believe that it does not have issues. I wonder if you already saw any issues by running that PR against these new tests. |
|
@vmoroz I commented at #57861 (comment). The change in that PR crashes this new test. |
|
Landed in 3b90f34 |
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test shows a critical case where a finalizer deletes an `napi_ref` whose finalizer is also scheduled. PR-URL: #57981 Reviewed-By: Vladimir Morozov <vmorozov@microsoft.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
Test that an napi_ref can be nested inside another ObjectWrap. The test
shows a critical case where a finalizer deletes an
napi_refwhosefinalizer is also scheduled.
This add a test for comments at:
node/src/node_api.cc
Lines 116 to 118 in 68cc1c9
The changes in
test/js-native-api/6_object_wrap/myobject.ccare auto-formatted bymake format-cppas the file is renamed.Refs: #57861 (review)