Skip to content

Commit

Permalink
[test] Remove comment to disable eslint rule
Browse files Browse the repository at this point in the history
  • Loading branch information
lpinca committed Mar 16, 2019
1 parent a40e29f commit 3df8242
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions test/websocket.test.js
Expand Up @@ -217,15 +217,13 @@ describe('WebSocket', function() {
wss.on('connection', (ws) => {
const data = Buffer.alloc(1024, 61);

// eslint-disable-next-line no-constant-condition
while (true) {
if (ws._socket.bufferSize > 0) {
assert.strictEqual(ws.bufferedAmount, ws._socket.bufferSize);
break;
}
while (ws._socket.bufferSize === 0) {
ws.send(data);
}

assert.ok(ws._socket.bufferSize > 0);
assert.strictEqual(ws.bufferedAmount, ws._socket.bufferSize);

ws.on('close', () => wss.close(done));
ws.close();
});
Expand Down

0 comments on commit 3df8242

Please sign in to comment.