镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions test/fetch/cookies.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ const { Client, fetch, Headers } = require('../..')
const pem = require('@metcoder95/https-pem')
const { createSecureServer } = require('node:http2')

const isMacOSNode20CI = process.platform === 'darwin' &&
Number(process.versions.node.split('.')[0]) === 20 &&
process.env.CI

describe('cookies', () => {
let server

Expand All @@ -28,7 +32,9 @@ describe('cookies', () => {
return once(server, 'close')
})

test('Can receive set-cookie headers from a server using fetch - issue #1262', async (t) => {
test('Can receive set-cookie headers from a server using fetch - issue #1262', {
skip: isMacOSNode20CI
}, async (t) => {
const query = qsStringify({
'set-cookie': 'name=value; Domain=example.com'
})
Expand Down Expand Up @@ -59,7 +65,9 @@ describe('cookies', () => {
}
})

test('Cookie header is delimited with a semicolon rather than a comma - issue #1905', async (t) => {
test('Cookie header is delimited with a semicolon rather than a comma - issue #1905', {
skip: isMacOSNode20CI
}, async (t) => {
const response = await fetch(`http://localhost:${server.address().port}`, {
headers: [
['cookie', 'FOO=lorem-ipsum-dolor-sit-amet'],
Expand Down
Loading