Skip to content

Commit

Permalink
test: fix assert.strictEqual() argument order
Browse files Browse the repository at this point in the history
PR-URL: #23564
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
  • Loading branch information
lotharthesavior authored and jasnell committed Oct 17, 2018
1 parent 7e79e01 commit ca24bcf
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions test/parallel/test-tcp-wrap-connect.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ function makeConnection() {
assert.strictEqual(err, 0);

req.oncomplete = function(status, client_, req_, readable, writable) {
assert.strictEqual(0, status);
assert.strictEqual(client, client_);
assert.strictEqual(req, req_);
assert.strictEqual(true, readable);
assert.strictEqual(true, writable);
assert.strictEqual(status, 0);
assert.strictEqual(client_, client);
assert.strictEqual(req_, req);
assert.strictEqual(readable, true);
assert.strictEqual(writable, true);

const shutdownReq = new ShutdownWrap();
const err = client.shutdown(shutdownReq);
assert.strictEqual(err, 0);

shutdownReq.oncomplete = function(status, client_, error) {
assert.strictEqual(0, status);
assert.strictEqual(client, client_);
assert.strictEqual(status, 0);
assert.strictEqual(client_, client);
assert.strictEqual(error, undefined);
shutdownCount++;
client.close();
Expand All @@ -55,7 +55,7 @@ const server = require('net').Server(function(s) {
server.listen(0, makeConnection);

process.on('exit', function() {
assert.strictEqual(1, shutdownCount);
assert.strictEqual(1, connectCount);
assert.strictEqual(1, endCount);
assert.strictEqual(shutdownCount, 1);
assert.strictEqual(connectCount, 1);
assert.strictEqual(endCount, 1);
});

0 comments on commit ca24bcf

Please sign in to comment.