Skip to content

Commit 280aed1

Browse files
carlrcjasnell
authored andcommittedOct 17, 2018
test: fix assertion argument order
PR-URL: #23489 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
1 parent 540c01a commit 280aed1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed
 

‎test/parallel/test-http-set-cookies.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ server.on('listening', function() {
4747
http.get({ port: this.address().port, path: '/one' }, function(res) {
4848
// set-cookie headers are always return in an array.
4949
// even if there is only one.
50-
assert.deepStrictEqual(['A'], res.headers['set-cookie']);
51-
assert.strictEqual('text/plain', res.headers['content-type']);
50+
assert.deepStrictEqual(res.headers['set-cookie'], ['A']);
51+
assert.strictEqual(res.headers['content-type'], 'text/plain');
5252

5353
res.on('data', function(chunk) {
5454
console.log(chunk.toString());
@@ -62,8 +62,8 @@ server.on('listening', function() {
6262
// two set-cookie headers
6363

6464
http.get({ port: this.address().port, path: '/two' }, function(res) {
65-
assert.deepStrictEqual(['A', 'B'], res.headers['set-cookie']);
66-
assert.strictEqual('text/plain', res.headers['content-type']);
65+
assert.deepStrictEqual(res.headers['set-cookie'], ['A', 'B']);
66+
assert.strictEqual(res.headers['content-type'], 'text/plain');
6767

6868
res.on('data', function(chunk) {
6969
console.log(chunk.toString());

0 commit comments

Comments
 (0)