diff options
author | Gibson Fahnestock <gib@uk.ibm.com> | 2017-01-08 15:36:25 +0000 |
---|---|---|
committer | Myles Borins <mylesborins@google.com> | 2017-04-18 20:01:52 -0400 |
commit | 6f85c81f0dc9e40511e98bd034c0a841ed764d3c (patch) | |
tree | e2572d38f2e9c0da2a5610cce4e3ae8f562e099e /test/parallel/test-http-upgrade-server.js | |
parent | afea1d041e2817551ead3e7703142d7567fbb58b (diff) | |
download | node-new-6f85c81f0dc9e40511e98bd034c0a841ed764d3c.tar.gz |
test: s/assert.equal/assert.strictEqual/
Use assert.strictEqual instead of assert.equal in tests, manually
convert types where necessary.
Backport-PR-URL: https://github.com/nodejs/node/pull/11795
PR-URL: https://github.com/nodejs/node/pull/10698
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Michaƫl Zasso <targos@protonmail.com>
Reviewed-By: Teddy Katz <teddy.katz@gmail.com>
Diffstat (limited to 'test/parallel/test-http-upgrade-server.js')
-rw-r--r-- | test/parallel/test-http-upgrade-server.js | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/test/parallel/test-http-upgrade-server.js b/test/parallel/test-http-upgrade-server.js index 6c5a62c2ff..c641f1576e 100644 --- a/test/parallel/test-http-upgrade-server.js +++ b/test/parallel/test-http-upgrade-server.js @@ -76,20 +76,20 @@ function test_upgrade_with_listener() { conn.on('data', function(data) { state++; - assert.equal('string', typeof data); + assert.strictEqual('string', typeof data); if (state === 1) { - assert.equal('HTTP/1.1 101', data.substr(0, 12)); - assert.equal('WjN}|M(6', request_upgradeHead.toString('utf8')); + assert.strictEqual('HTTP/1.1 101', data.substr(0, 12)); + assert.strictEqual('WjN}|M(6', request_upgradeHead.toString('utf8')); conn.write('test', 'utf8'); } else if (state === 2) { - assert.equal('test', data); + assert.strictEqual('test', data); conn.write('kill', 'utf8'); } }); conn.on('end', function() { - assert.equal(2, state); + assert.strictEqual(2, state); conn.end(); server.removeAllListeners('upgrade'); test_upgrade_no_listener(); @@ -135,8 +135,8 @@ function test_standard_http() { }); conn.once('data', function(data) { - assert.equal('string', typeof data); - assert.equal('HTTP/1.1 200', data.substr(0, 12)); + assert.strictEqual('string', typeof data); + assert.strictEqual('HTTP/1.1 200', data.substr(0, 12)); conn.end(); }); @@ -158,7 +158,7 @@ server.listen(0, function() { Fin. -----------------------------------------------*/ process.on('exit', function() { - assert.equal(3, requests_recv); - assert.equal(3, requests_sent); + assert.strictEqual(3, requests_recv); + assert.strictEqual(3, requests_sent); assert.ok(test_upgrade_no_listener_ended); }); |