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 targos committed Jun 11, 2021
1 parent f903ad8 commit e82111f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions test/parallel/test-http-outgoing-internal-headers.js
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 e82111f

Please sign in to comment.