mirror of
https://github.com/nodejs/node.git
synced 2026-11-21 12:59:16 -05:00
test: pummel/test-net-throttle adhere to streams
bufferSize is now a getter that shows all that has not been acknowledged by the os, as well as in the buffer state. The test is only looking to verify the js verified state.
This commit is contained in:
1 parent
3a3b7488b5
commit
95bb347d6c
1 file changed
+2
-2
@@ -43,8 +43,8 @@ var server = net.createServer(function(connection) {
|
||||
connection.write(body.slice(0, part_N));
|
||||
connection.write(body.slice(part_N, 2 * part_N));
|
||||
assert.equal(false, connection.write(body.slice(2 * part_N, N)));
|
||||
console.log('bufferSize: ' + connection.bufferSize);
|
||||
assert.ok(0 <= connection.bufferSize && connection.bufferSize <= N);
|
||||
console.log('bufferSize: ' + connection.bufferSize, 'expecting', N);
|
||||
assert.ok(0 <= connection.bufferSize && connection._writableState.length <= N);
|
||||
connection.end();
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user