mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
ci: add conditional for node 16 test
This commit is contained in:
parent
603e7e7fb1
commit
aee1218e61
@ -600,9 +600,12 @@ describe('errors', () => {
|
|||||||
|
|
||||||
it('should render a HTML error page', async () => {
|
it('should render a HTML error page', async () => {
|
||||||
const res = await fetch('/error')
|
const res = await fetch('/error')
|
||||||
expect(res.headers.get('Set-Cookie')).toBe('set-in-plugin=true; Path=/')
|
// TODO: remove when we update CI to node v18
|
||||||
// TODO: enable when we update test to node v16
|
if (process.version.startsWith('v16')) {
|
||||||
// expect(res.headers.get('Set-Cookie')).toBe('set-in-plugin=true; Path=/, some-error=was%20set; Path=/')
|
expect(res.headers.get('Set-Cookie')).toBe('set-in-plugin=true; Path=/')
|
||||||
|
} else {
|
||||||
|
expect(res.headers.get('Set-Cookie')).toBe('set-in-plugin=true; Path=/, some-error=was%20set; Path=/')
|
||||||
|
}
|
||||||
expect(await res.text()).toContain('This is a custom error')
|
expect(await res.text()).toContain('This is a custom error')
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user