Skip to content

Commit

Permalink
test: http outgoing _headers setter null
Browse files Browse the repository at this point in the history
Co-authored-by: Qingyu Deng <i@ayase-lab.com>

PR-URL: #38881
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
  • Loading branch information
ycjcl868 authored and richardlau committed Jul 20, 2021
1 parent 41fcbad commit c99a09f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test/parallel/test-http-outgoing-internal-headers.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,14 @@ common.expectWarning('DeprecationWarning', warn, 'DEP0066');
origin: ['Origin', 'localhost']
}));
}

{
// Tests for _headers set method `null`
const outgoingMessage = new OutgoingMessage();
outgoingMessage._headers = null;

assert.strictEqual(
outgoingMessage[kOutHeaders],
null
);
}

0 comments on commit c99a09f

Please sign in to comment.