Skip to content

Commit

Permalink
add additional header test
Browse files Browse the repository at this point in the history
  • Loading branch information
lalitkapoor committed Feb 6, 2014
1 parent 7fb1647 commit d6b2b1c
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/test-headers.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,14 @@ s.listen(s.port, function () {
assert.equal(req.headers.cookie, 'foo=bar; quux=baz')
})

// Issue #794 add ability to ignore cookie parsing and domain errors
var jar2 = request.jar()
jar2.setCookie('quux=baz; Domain=foo.bar.com', serverUri, {ignoreError: true});
createTest({jar: jar2, headers: {cookie: 'foo=bar'}}, function (req, res) {
assert.ok(req.headers.cookie)
assert.equal(req.headers.cookie, 'foo=bar')
})

// Issue #784: override content-type when json is used
// https://github.com/mikeal/request/issues/784
createTest({
Expand Down

0 comments on commit d6b2b1c

Please sign in to comment.