From e76d10fdbc3df95f5bee0903aba4ed0516798ac6 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Wed, 20 Feb 2019 07:54:56 -0800 Subject: [PATCH] test: add (temporary) logging for unreliable test Refs: https://github.com/nodejs/node/issues/25984 --- test/pummel/test-crypto-timing-safe-equal-benchmarks.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/pummel/test-crypto-timing-safe-equal-benchmarks.js b/test/pummel/test-crypto-timing-safe-equal-benchmarks.js index 0592b9a0d63674..98e95fbb895232 100644 --- a/test/pummel/test-crypto-timing-safe-equal-benchmarks.js +++ b/test/pummel/test-crypto-timing-safe-equal-benchmarks.js @@ -24,6 +24,7 @@ function runOneBenchmark(...args) { } function getTValue(compareFunc) { + console.log(compareFunc.name); const numTrials = 1e5; const bufSize = 10000; // Perform benchmarks to verify that timingSafeEqual is actually timing-safe. @@ -32,6 +33,9 @@ function getTValue(compareFunc) { const rawUnequalBenches = Array(numTrials); for (let i = 0; i < numTrials; i++) { + if (i % 1000 === 0) { + console.log(i); + } if (Math.random() < 0.5) { // First benchmark: comparing two equal buffers rawEqualBenches[i] = runOneBenchmark(compareFunc, 'A', 'A', bufSize);