Skip to content

Commit

Permalink
test: fix and improve error message
Browse files Browse the repository at this point in the history
Add unexpected value to dgram socket type assertion and fix the size
entry.

PR-URL: #18449
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
kcaulfield94 authored and BridgeAR committed Feb 12, 2018
1 parent c3ff899 commit 18e7284
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/parallel/test-dgram-createSocket-type.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,12 @@ validTypes.forEach((validType) => {
// note: linux will double the buffer size
assert.ok(socket.getRecvBufferSize() === 10000 ||
socket.getRecvBufferSize() === 20000,
'SO_RCVBUF not 1300 or 2600');
'SO_RCVBUF not 10000 or 20000, ' +
`was ${socket.getRecvBufferSize()}`);
assert.ok(socket.getSendBufferSize() === 15000 ||
socket.getSendBufferSize() === 30000,
'SO_SNDBUF not 1800 or 3600');
'SO_SNDBUF not 15000 or 30000, ' +
`was ${socket.getRecvBufferSize()}`);
socket.close();
}));
}

0 comments on commit 18e7284

Please sign in to comment.