From 20d4cba61a4610b9ed9552a174c365a11455a599 Mon Sep 17 00:00:00 2001 From: Sean Healy Date: Fri, 12 Oct 2018 11:42:58 -0700 Subject: [PATCH] test: update assertion parameter order MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Update assertions to be `value`, `expectedValue`. PR-URL: https://github.com/nodejs/node/pull/23614 Reviewed-By: James M Snell Reviewed-By: Ruben Bridgewater Reviewed-By: Anna Henningsen Reviewed-By: Сковорода Никита Андреевич Reviewed-By: Trivikram Kamat Reviewed-By: Colin Ihrig Reviewed-By: Gireesh Punathil Reviewed-By: Sakthipriyan Vairamani --- test/parallel/test-http-proxy.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/test/parallel/test-http-proxy.js b/test/parallel/test-http-proxy.js index 8781679c0a45b8..6a986024af29be 100644 --- a/test/parallel/test-http-proxy.js +++ b/test/parallel/test-http-proxy.js @@ -50,9 +50,9 @@ const proxy = http.createServer(function(req, res) { console.error(`proxy res headers: ${JSON.stringify(proxy_res.headers)}`); - assert.strictEqual('world', proxy_res.headers.hello); - assert.strictEqual('text/plain', proxy_res.headers['content-type']); - assert.deepStrictEqual(cookies, proxy_res.headers['set-cookie']); + assert.strictEqual(proxy_res.headers.hello, 'world'); + assert.strictEqual(proxy_res.headers['content-type'], 'text/plain'); + assert.deepStrictEqual(proxy_res.headers['set-cookie'], cookies); res.writeHead(proxy_res.statusCode, proxy_res.headers); @@ -79,11 +79,11 @@ function startReq() { path: '/test' }, function(res) { console.error('got res'); - assert.strictEqual(200, res.statusCode); + assert.strictEqual(res.statusCode, 200); - assert.strictEqual('world', res.headers.hello); - assert.strictEqual('text/plain', res.headers['content-type']); - assert.deepStrictEqual(cookies, res.headers['set-cookie']); + assert.strictEqual(res.headers.hello, 'world'); + assert.strictEqual(res.headers['content-type'], 'text/plain'); + assert.deepStrictEqual(res.headers['set-cookie'], cookies); res.setEncoding('utf8'); res.on('data', function(chunk) { body += chunk; });