From 4b1855654f5966c202087600f113dbda2567188b Mon Sep 17 00:00:00 2001 From: alexlamsl Date: Tue, 18 Feb 2020 04:04:05 +0800 Subject: [PATCH] improve `--reduce-test` - print out Node.js and OS information --- test/reduce.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/reduce.js b/test/reduce.js index 0d803aad..557fffd5 100644 --- a/test/reduce.js +++ b/test/reduce.js @@ -1,6 +1,7 @@ var crypto = require("crypto"); var U = require("./node"); var List = U.List; +var os = require("os"); var sandbox = require("./sandbox"); // Reduce a ufuzz-style `console.log` based test case by iteratively replacing @@ -29,6 +30,9 @@ module.exports = function reduce_test(testcase, minify_options, reduce_options) // the initial timeout to assess the viability of the test case must be large var differs = producesDifferentResultWhenMinified(result_cache, testcase, minify_options, max_timeout); + if (verbose) { + console.error("// Node.js " + process.version + " on " + os.platform() + " " + os.arch()); + } if (!differs) { // same stdout result produced when minified return {