From ed2014231791fd4ebf4580137bd5df641bff1901 Mon Sep 17 00:00:00 2001 From: Braden Whitten Date: Fri, 6 Oct 2017 16:13:43 -0700 Subject: [PATCH] test: remove error messages in test-buffer-alloc PR-URL: https://github.com/nodejs/node/pull/15867 Reviewed-By: James M Snell Reviewed-By: Ruben Bridgewater --- test/parallel/test-buffer-alloc.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test/parallel/test-buffer-alloc.js b/test/parallel/test-buffer-alloc.js index 6db742e9561ca8..d0f02b114c1f97 100644 --- a/test/parallel/test-buffer-alloc.js +++ b/test/parallel/test-buffer-alloc.js @@ -309,12 +309,12 @@ assert.strictEqual('TWFu', (Buffer.from('Man')).toString('base64')); assert.strictEqual(quote, b.toString('ascii', 0, quote.length)); // check that the base64 decoder ignores whitespace - const expectedWhite = expected.slice(0, 60) + ' \n' + - expected.slice(60, 120) + ' \n' + - expected.slice(120, 180) + ' \n' + - expected.slice(180, 240) + ' \n' + - expected.slice(240, 300) + '\n' + - expected.slice(300, 360) + '\n'; + const expectedWhite = `${expected.slice(0, 60)} \n` + + `${expected.slice(60, 120)} \n` + + `${expected.slice(120, 180)} \n` + + `${expected.slice(180, 240)} \n` + + `${expected.slice(240, 300)}\n` + + `${expected.slice(300, 360)}\n`; b = Buffer.allocUnsafe(1024); bytesWritten = b.write(expectedWhite, 0, 'base64'); assert.strictEqual(quote.length, bytesWritten);