From 8bb59fdb127b060d38430c0428d7783931ebec6e Mon Sep 17 00:00:00 2001 From: Andreas Madsen Date: Tue, 31 May 2016 21:49:16 +0200 Subject: benchmark: missing process.exit after bench.end Previously bench.end would call process.exit(0) however this is rather confusing and indeed a few benchmarks had code that assumed otherwise. This adds process.exit(0) to the benchmarks that needs it. PR-URL: https://github.com/nodejs/node/pull/7094 Reviewed-By: Trevor Norris Reviewed-By: Jeremiah Senkpiel Reviewed-By: Brian White Reviewed-By: Anna Henningsen --- benchmark/dgram/array-vs-concat.js | 1 + benchmark/dgram/multi-buffer.js | 1 + benchmark/dgram/offset-length.js | 1 + benchmark/dgram/single-buffer.js | 1 + 4 files changed, 4 insertions(+) (limited to 'benchmark/dgram') diff --git a/benchmark/dgram/array-vs-concat.js b/benchmark/dgram/array-vs-concat.js index 2a82ea48c7..1f07a50423 100644 --- a/benchmark/dgram/array-vs-concat.js +++ b/benchmark/dgram/array-vs-concat.js @@ -67,6 +67,7 @@ function server() { var bytes = sent * len; var gbits = (bytes * 8) / (1024 * 1024 * 1024); bench.end(gbits); + process.exit(0); }, dur * 1000); }); diff --git a/benchmark/dgram/multi-buffer.js b/benchmark/dgram/multi-buffer.js index e7292feb1f..85e9561de8 100644 --- a/benchmark/dgram/multi-buffer.js +++ b/benchmark/dgram/multi-buffer.js @@ -58,6 +58,7 @@ function server() { var bytes = (type === 'send' ? sent : received) * len; var gbits = (bytes * 8) / (1024 * 1024 * 1024); bench.end(gbits); + process.exit(0); }, dur * 1000); }); diff --git a/benchmark/dgram/offset-length.js b/benchmark/dgram/offset-length.js index 15d9a3d0ee..ce9f4b025a 100644 --- a/benchmark/dgram/offset-length.js +++ b/benchmark/dgram/offset-length.js @@ -50,6 +50,7 @@ function server() { var bytes = (type === 'send' ? sent : received) * chunk.length; var gbits = (bytes * 8) / (1024 * 1024 * 1024); bench.end(gbits); + process.exit(0); }, dur * 1000); }); diff --git a/benchmark/dgram/single-buffer.js b/benchmark/dgram/single-buffer.js index 2676e0e74c..4793f65eea 100644 --- a/benchmark/dgram/single-buffer.js +++ b/benchmark/dgram/single-buffer.js @@ -50,6 +50,7 @@ function server() { var bytes = (type === 'send' ? sent : received) * chunk.length; var gbits = (bytes * 8) / (1024 * 1024 * 1024); bench.end(gbits); + process.exit(0); }, dur * 1000); }); -- cgit v1.2.1