Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
test: correct isReused parameter in test-http-parser
Pass true for isReused in the two reinitialize calls to better reflect
the actual usage here.
  • Loading branch information
basti1302 committed Oct 10, 2018
commit b4c542f2b167a0b71c2a531f376028038952888d
4 changes: 2 additions & 2 deletions test/parallel/test-http-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ function expectBody(expected) {
throw new Error('hello world');
};

parser.reinitialize(HTTPParser.REQUEST, false);
parser.reinitialize(HTTPParser.REQUEST, true);

assert.throws(
() => { parser.execute(request, 0, request.length); },
Expand Down Expand Up @@ -558,7 +558,7 @@ function expectBody(expected) {
parser[kOnBody] = expectBody('ping');
parser.execute(req1, 0, req1.length);

parser.reinitialize(REQUEST, false);
parser.reinitialize(REQUEST, true);
parser[kOnBody] = expectBody('pong');
parser[kOnHeadersComplete] = onHeadersComplete2;
parser.execute(req2, 0, req2.length);
Expand Down