diff options
author | Pete Lombardo <obxpete@gmail.com> | 2018-10-12 14:02:44 -0400 |
---|---|---|
committer | Ruben Bridgewater <ruben@bridgewater.de> | 2018-10-15 15:34:45 +0200 |
commit | 22afe4fafced0cd4b411937e476f9fd939b22b2d (patch) | |
tree | 79f9f232cc2fcfa95e02c8f60ea2b876bea899d2 /test/pummel | |
parent | 8a32a5188153d9f67866e159ff06c4ea061a1fce (diff) | |
download | android-node-v8-22afe4fafced0cd4b411937e476f9fd939b22b2d.tar.gz android-node-v8-22afe4fafced0cd4b411937e476f9fd939b22b2d.tar.bz2 android-node-v8-22afe4fafced0cd4b411937e476f9fd939b22b2d.zip |
test: fix parameter order of assertions
PR-URL: https://github.com/nodejs/node/pull/23565
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Diffstat (limited to 'test/pummel')
-rw-r--r-- | test/pummel/test-net-throttle.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/pummel/test-net-throttle.js b/test/pummel/test-net-throttle.js index a08ed85ccd..fb060c9d76 100644 --- a/test/pummel/test-net-throttle.js +++ b/test/pummel/test-net-throttle.js @@ -37,7 +37,7 @@ console.log(`start server on port ${common.PORT}`); const server = net.createServer(function(connection) { connection.write(body.slice(0, part_N)); connection.write(body.slice(part_N, 2 * part_N)); - assert.strictEqual(false, connection.write(body.slice(2 * part_N, N))); + assert.strictEqual(connection.write(body.slice(2 * part_N, N)), false); console.log(`bufferSize: ${connection.bufferSize}`, 'expecting', N); assert.ok(connection.bufferSize >= 0 && connection.writableLength <= N); @@ -58,7 +58,7 @@ server.listen(common.PORT, function() { console.log('pause'); const x = chars_recved; setTimeout(function() { - assert.strictEqual(chars_recved, x); + assert.strictEqual(x, chars_recved); client.resume(); console.log('resume'); paused = false; @@ -74,6 +74,6 @@ server.listen(common.PORT, function() { process.on('exit', function() { - assert.strictEqual(N, chars_recved); - assert.strictEqual(true, npauses > 2); + assert.strictEqual(chars_recved, N); + assert.strictEqual(npauses > 2, true); }); |