From 2976bbd68f936c4f96b6028219ceb9bfc4b84f22 Mon Sep 17 00:00:00 2001 From: Sam Roberts Date: Sun, 2 Jun 2019 18:19:44 +0200 Subject: [PATCH] test: only assert on first lines of TLS trace The TLS trace data is best-effort, and enough can be dropped from pipe buffers that only the start of the trace is detected. Only assert on the first line of the trace, it should not get dropped, and it's enough to check that trace was enabled via CLI. PR-URL: https://github.com/nodejs/node/pull/28043 Fixes: https://github.com/nodejs/node/issues/27636 Reviewed-By: Luigi Pinca Reviewed-By: Colin Ihrig Reviewed-By: Richard Lau Reviewed-By: Ruben Bridgewater --- test/parallel/parallel.status | 2 -- test/parallel/test-tls-enable-trace-cli.js | 1 - 2 files changed, 3 deletions(-) diff --git a/test/parallel/parallel.status b/test/parallel/parallel.status index 965e378bfd952b..45718e7903388e 100644 --- a/test/parallel/parallel.status +++ b/test/parallel/parallel.status @@ -9,8 +9,6 @@ prefix parallel test-net-connect-options-port: PASS,FLAKY # https://github.com/nodejs/node/issues/26401 test-worker-prof: PASS,FLAKY -# https://github.com/nodejs/node/issues/27553 -test-tls-enable-trace-cli: PASS,FLAKY [$system==win32] test-http2-pipe: PASS,FLAKY diff --git a/test/parallel/test-tls-enable-trace-cli.js b/test/parallel/test-tls-enable-trace-cli.js index 4d3065e757fce6..951dca4a87f1ed 100644 --- a/test/parallel/test-tls-enable-trace-cli.js +++ b/test/parallel/test-tls-enable-trace-cli.js @@ -37,7 +37,6 @@ child.on('close', common.mustCall((code, signal) => { assert.strictEqual(stdout.trim(), ''); assert(/Warning: Enabling --trace-tls can expose sensitive/.test(stderr)); assert(/Sent Record/.test(stderr)); - assert(/Received Record/.test(stderr)); })); function test() {