Skip to content

Commit

Permalink
Pin version of nwsapi (revert later)
Browse files Browse the repository at this point in the history
The latest version of `nwsapi` (which is a peer dependency of
`jest-environment-jsdom > jsdom`) causes `ReferenceError: document is
not defined` errors in some of our tests. We're pinning the old working
version until dperini/nwsapi#135 is resolved.
  • Loading branch information
unstubbable committed Nov 29, 2024
1 parent 406878f commit 7747f02
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/production/jest/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,10 @@ describe('next/jest', () => {
'@testing-library/jest-dom': '5.16.1',
'@testing-library/react': '15.0.2',
'@testing-library/user-event': '14.5.2',
// TODO: nwsapi is a peer dep of jest-environment-jsdom > jsdom. We're
// temporarily pinning the version here because later versions cause
// `ReferenceError: document is not defined`
nwsapi: '2.2.13',
},
packageJson: {
scripts: {
Expand Down
4 changes: 4 additions & 0 deletions test/production/jest/new-link-behavior.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ describe('next/jest newLinkBehavior', () => {
jest: '29.7.0',
'jest-environment-jsdom': '29.7.0',
'@testing-library/react': '15.0.2',
// TODO: nwsapi is a peer dep of jest-environment-jsdom > jsdom. We're
// temporarily pinning the version here because later versions cause
// `ReferenceError: document is not defined`
nwsapi: '2.2.13',
},
packageJson: {
scripts: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ describe('next/jest', () => {
'jest-environment-jsdom': '29.7.0',
'@testing-library/react': '15.0.2',
'@testing-library/jest-dom': '5.17.0',
// TODO: nwsapi is a peer dep of jest-environment-jsdom > jsdom. We're
// temporarily pinning the version here because later versions cause
// `ReferenceError: document is not defined`
nwsapi: '2.2.13',
},
})
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ describe('next/jest', () => {
'jest-environment-jsdom': '29.7.0',
'@testing-library/react': '15.0.2',
'@testing-library/jest-dom': '5.16.4',
// TODO: nwsapi is a peer dep of jest-environment-jsdom > jsdom. We're
// temporarily pinning the version here because later versions cause
// `ReferenceError: document is not defined`
nwsapi: '2.2.13',
},
packageJson: {
scripts: {
Expand Down

0 comments on commit 7747f02

Please sign in to comment.