summaryrefslogtreecommitdiff
path: root/test/parallel/test-tcp-wrap.js
diff options
context:
space:
mode:
authorJames M Snell <jasnell@gmail.com>2018-08-06 14:40:30 -0700
committerJames M Snell <jasnell@gmail.com>2018-08-09 13:47:31 -0700
commitc7962dcba46f44b888686e6a76bcc6fef2eb7760 (patch)
tree247db2bcd4f0673adf5ccad86ed7fc58286e7c9b /test/parallel/test-tcp-wrap.js
parent2fd71f92381010724e24cd07d505f76e63b16394 (diff)
downloadnode-new-c7962dcba46f44b888686e6a76bcc6fef2eb7760.tar.gz
src: move process.binding('uv') to internalBinding
PR-URL: https://github.com/nodejs/node/pull/22163 Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Tiancheng "Timothy" Gu <timothygu99@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Jon Moss <me@jonathanmoss.me>
Diffstat (limited to 'test/parallel/test-tcp-wrap.js')
-rw-r--r--test/parallel/test-tcp-wrap.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/parallel/test-tcp-wrap.js b/test/parallel/test-tcp-wrap.js
index 36a45d7606..f6a54a012b 100644
--- a/test/parallel/test-tcp-wrap.js
+++ b/test/parallel/test-tcp-wrap.js
@@ -1,3 +1,4 @@
+// Flags: --expose-internals
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
@@ -24,7 +25,8 @@ require('../common');
const assert = require('assert');
const { TCP, constants: TCPConstants } = process.binding('tcp_wrap');
-const uv = process.binding('uv');
+const { internalBinding } = require('internal/test/binding');
+const { UV_EINVAL } = internalBinding('uv');
const handle = new TCP(TCPConstants.SOCKET);
@@ -36,6 +38,6 @@ assert.strictEqual(err, 0);
const out = {};
handle.getsockname(out);
err = handle.bind('0.0.0.0', out.port);
-assert.strictEqual(err, uv.UV_EINVAL);
+assert.strictEqual(err, UV_EINVAL);
handle.close();