Skip to content

Commit a69d8b2

Browse files
Jake ChampionJakeChampion
authored andcommitted
chore: add test to confirm that lots of the same header is supported
1 parent 96bd2ce commit a69d8b2

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed

integration-tests/js-compute/fixtures/multiple-set-cookie/bin/index.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,14 @@ routes.set('/', () => {
3737
h.append("Set-Cookie", "test=1; expires=Tue, 06-Dec-2022 12:34:56 GMT; Max-Age=60; Path=/; HttpOnly; Secure, test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT, test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT");
3838
h.append("Set-Cookie", "test2=2");
3939
h.append("Set-Cookie", "test3=3");
40+
h.append("Set-Cookie", "test4=4");
41+
h.append("Set-Cookie", "test5=5");
42+
h.append("Set-Cookie", "test6=6");
43+
h.append("Set-Cookie", "test7=7");
44+
h.append("Set-Cookie", "test8=8");
45+
h.append("Set-Cookie", "test9=9");
46+
h.append("Set-Cookie", "test10=10");
47+
h.append("Set-Cookie", "test11=11");
4048

4149
let r = new Response("Hello", {
4250
headers: h
@@ -49,6 +57,14 @@ routes.set('/', () => {
4957
r.headers.append("Set-Cookie", "test=1; expires=Tue, 06-Dec-2022 12:34:56 GMT; Max-Age=60; Path=/; HttpOnly; Secure, test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT, test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT");
5058
r.headers.append("Set-Cookie", "test2=2");
5159
r.headers.append("Set-Cookie", "test3=3");
60+
r.headers.append("Set-Cookie", "test4=4");
61+
r.headers.append("Set-Cookie", "test5=5");
62+
r.headers.append("Set-Cookie", "test6=6");
63+
r.headers.append("Set-Cookie", "test7=7");
64+
r.headers.append("Set-Cookie", "test8=8");
65+
r.headers.append("Set-Cookie", "test9=9");
66+
r.headers.append("Set-Cookie", "test10=10");
67+
r.headers.append("Set-Cookie", "test11=11");
5268
return r;
5369
});
5470
}

integration-tests/js-compute/fixtures/multiple-set-cookie/tests.json

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,15 @@
1212
["Set-Cookie", "test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT"],
1313
["Set-Cookie", "test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT"],
1414
["Set-Cookie", "test2=2"],
15-
["Set-Cookie", "test3=3"]
15+
["Set-Cookie", "test3=3"],
16+
["Set-Cookie", "test4=4"],
17+
["Set-Cookie", "test5=5"],
18+
["Set-Cookie", "test6=6"],
19+
["Set-Cookie", "test7=7"],
20+
["Set-Cookie", "test8=8"],
21+
["Set-Cookie", "test9=9"],
22+
["Set-Cookie", "test10=10"],
23+
["Set-Cookie", "test11=11"]
1624
]
1725
}
1826
},
@@ -29,7 +37,15 @@
2937
["Set-Cookie", "test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT"],
3038
["Set-Cookie", "test_id=1; Max-Age=60; Path=/; expires=Tue, 06-Dec-2022 12:34:56 GMT"],
3139
["Set-Cookie", "test2=2"],
32-
["Set-Cookie", "test3=3"]
40+
["Set-Cookie", "test3=3"],
41+
["Set-Cookie", "test4=4"],
42+
["Set-Cookie", "test5=5"],
43+
["Set-Cookie", "test6=6"],
44+
["Set-Cookie", "test7=7"],
45+
["Set-Cookie", "test8=8"],
46+
["Set-Cookie", "test9=9"],
47+
["Set-Cookie", "test10=10"],
48+
["Set-Cookie", "test11=11"]
3349
]
3450
}
3551
}

0 commit comments

Comments
 (0)