From adbc5d7d57c17a8eb7ce69ad763394ade55202c3 Mon Sep 17 00:00:00 2001 From: Martin Michaelis Date: Fri, 6 Oct 2017 09:55:06 -0700 Subject: [PATCH] test: rewrite assert message MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `test/parallel/test-zlib-unzip-one-byte-chunks.js` uses a literal string to describe the error if the string does not match itself after zipping and unzipping. Changed to a more descriptive template literal. PR-URL: https://github.com/nodejs/node/pull/15879 Reviewed-By: James M Snell Reviewed-By: Tobias Nießen Reviewed-By: Luigi Pinca --- test/parallel/test-zlib-unzip-one-byte-chunks.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/parallel/test-zlib-unzip-one-byte-chunks.js b/test/parallel/test-zlib-unzip-one-byte-chunks.js index 50a383af18329d..be3b5dda818cf6 100644 --- a/test/parallel/test-zlib-unzip-one-byte-chunks.js +++ b/test/parallel/test-zlib-unzip-one-byte-chunks.js @@ -17,7 +17,9 @@ const unzip = zlib.createUnzip() .on('data', (data) => resultBuffers.push(data)) .on('finish', common.mustCall(() => { assert.deepStrictEqual(Buffer.concat(resultBuffers).toString(), 'abcdef', - 'result should match original string'); + `'${Buffer.concat(resultBuffers).toString()}' ` + + 'should match \'abcdef\' after ' + + 'zipping and unzipping'); })); for (let i = 0; i < data.length; i++) {