-
Notifications
You must be signed in to change notification settings - Fork 30.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: remove dependency on node-weak #11239
Conversation
|
@richardlau Right you are, updated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
node-weak
is also referenced in the LICENSE
file via tools/license-builder.sh.
test/gc/binding.js
Outdated
try { | ||
module.exports = require('./build/Release/binding').ongc; | ||
} catch (e) { | ||
module.exports = require('./build/Debug/binding').ongc; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it correct to prefer a binding in Release (e.g. if tests are run with node_g
)?
For example, build and test Release and then build and test Debug without cleaning in-between.
I don't think it's possible for the makefile
to build the binding in debug mode (it always runs node-gyp
with the Release node) -- vcbuild.bat
runs node-gyp with "%config%\node"
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You're right that the build won't compile a debug version but it seems convenient for manual testing/debugging. What would you do instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Try to load the version that matched the mode (release/debug) of the node process first and fallback to the other?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a bad idea but I decided to use the same logic we use in test/addons for the sake of consistency. PTAL.
e2f2ba9
to
92aaa38
Compare
Funny, I didn't even realize I own the copyright. At any rate, removed! |
45c894a
to
cc9955a
Compare
Rewrite the tests in test/gc so that they no longer call process.exit(). Instead they exit gracefully now. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB and the size of the tarball by about 150-300 kB. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Since the previous commit obsoleted them, remove them. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
cc9955a
to
75019df
Compare
Rewrite the tests in test/gc so that they no longer call process.exit(). Instead they exit gracefully now. PR-URL: #11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB and the size of the tarball by about 150-300 kB. PR-URL: #11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Since the previous commit obsoleted them, remove them. PR-URL: #11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Rewrite the tests in test/gc so that they no longer call process.exit(). Instead they exit gracefully now. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB and the size of the tarball by about 150-300 kB. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Since the previous commit obsoleted them, remove them. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Rewrite the tests in test/gc so that they no longer call process.exit(). Instead they exit gracefully now. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB and the size of the tarball by about 150-300 kB. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Since the previous commit obsoleted them, remove them. PR-URL: nodejs#11239 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com>
needs backport PRs to land in v4 or v6 |
Replace node-weak with a small hand-rolled add-on. We can now drop node-weak and nan, reducing the size of the source tree by about 750 kB (and the size of the tarball by about 150-300 kB.)
The first commit cleans up the tests, the second introduces the add-on, the third one drops nan and node-weak.