summaryrefslogtreecommitdiff
path: root/test/parallel/test-dgram-send-callback-buffer-empty-address.js
diff options
context:
space:
mode:
authorArtur Vieira <vieira.artur.g@gmail.com>2017-05-10 23:17:24 +0000
committerLuigi Pinca <luigipinca@gmail.com>2017-05-22 08:38:57 +0200
commit4c847347c3e8dd3198be2d2d71728521a1f42281 (patch)
tree665b093f4a50d684073a1ea0f7da04f661feb444 /test/parallel/test-dgram-send-callback-buffer-empty-address.js
parent330c8d743e33a83f85389ea8a64e3d3854ea0048 (diff)
downloadandroid-node-v8-4c847347c3e8dd3198be2d2d71728521a1f42281.tar.gz
android-node-v8-4c847347c3e8dd3198be2d2d71728521a1f42281.tar.bz2
android-node-v8-4c847347c3e8dd3198be2d2d71728521a1f42281.zip
test: replace common.PORT in dgram test
Replace common.PORT with available port assigned by the operating system in test-dgram-send-callback-buffer-empty-address. PR-URL: https://github.com/nodejs/node/pull/12929 Refs: https://github.com/nodejs/node/issues/12376 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Diffstat (limited to 'test/parallel/test-dgram-send-callback-buffer-empty-address.js')
-rw-r--r--test/parallel/test-dgram-send-callback-buffer-empty-address.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/parallel/test-dgram-send-callback-buffer-empty-address.js b/test/parallel/test-dgram-send-callback-buffer-empty-address.js
index 67e64d6bfe..5b3b1c41a1 100644
--- a/test/parallel/test-dgram-send-callback-buffer-empty-address.js
+++ b/test/parallel/test-dgram-send-callback-buffer-empty-address.js
@@ -14,4 +14,4 @@ const onMessage = common.mustCall(function(err, bytes) {
client.close();
});
-client.send(buf, common.PORT, onMessage);
+client.bind(0, () => client.send(buf, client.address().port, onMessage));