-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(deps): update jest monorepo to v29 (version-4) (major) #6850
chore(deps): update jest monorepo to v29 (version-4) (major) #6850
Conversation
✅ Deploy Preview for apollo-server-docs ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit c99e405:
|
As usual our Jest upgrade is blocked on ts-jest. |
6d5dda8
to
0e285a6
Compare
3b29c21
to
68d1cc9
Compare
3d963e4
to
79ca0a9
Compare
a7c62ed
to
065da89
Compare
@glasser it looks like adopting ESM mode comes with the requirement of importing jest globals everywhere. This maybe only surfaced after updating to v29? Majority of the changes within are updating snapshots due to a simpler serialization format for objects and adding jest imports everywhere. I removed My preference is to land this before RC because the integration testsuite has a peer dependency on jest. Though maybe it'll support v28 and v29 fine? Integrations are presumably all greenfield though, so I'd prefer to just have them all on the latest major. |
cac020f
to
ef11e67
Compare
Native ESM requires importing That's not a difference between v28 and v29, tho - it's been that way all the time. And if you want to reduce the diff, you can either configure |
Ref: #6850 (comment) <!-- First, 🌠 thank you 🌠 for taking the time to consider a contribution to Apollo! Here are some important details to follow: * ⏰ Your time is important To save your precious time, if the contribution you are making will take more than an hour, please make sure it has been discussed in an issue first. This is especially true for feature requests! * 💡 Features Feature requests can be created and discussed within a GitHub Issue. Be sure to search for existing feature requests (and related issues!) prior to opening a new request. If an existing issue covers the need, please upvote that issue by using the 👍 emote, rather than opening a new issue. * 🔌 Integrations Apollo Server has many web-framework integrations including Express, Koa, Hapi and more. When adding a new feature, or fixing a bug, please take a peak and see if other integrations are also affected. In most cases, the fix can be applied to the other frameworks as well. Please note that, since new web-frameworks have a high maintenance cost, pull-requests for new web-frameworks should be discussed with a project maintainer first. * 🕷 Bug fixes These can be created and discussed in this repository. When fixing a bug, please _try_ to add a test which verifies the fix. If you cannot, you should still submit the PR but we may still ask you (and help you!) to create a test. * 📖 Contribution guidelines Follow https://github.com/apollographql/apollo-server/blob/main/CONTRIBUTING.md when submitting a pull request. Make sure existing tests still pass, and add tests for all new behavior. * ✏️ Explain your pull request Describe the big picture of your changes here to communicate to what your pull request is meant to accomplish. Provide 🔗 links 🔗 to associated issues! We hope you will find this to be a positive experience! Open source contribution can be intimidating and we hope to alleviate that pain as much as possible. Without following these guidelines, you may be missing context that can help you succeed with your contribution, which is why we encourage discussion first. Ultimately, there is no guarantee that we will be able to merge your pull-request, but by following these guidelines we can try to avoid disappointment. -->
In ESM mode, the `jest` globals are technically no longer available. For some reason, we're still getting away with it, but this issue surfaces in the v29 upgrade PR so I'm going to address it separately. https://jestjs.io/docs/ecmascript-modules#differences-between-esm-and-commonjs Ref: #6850 (comment) <!-- First, 🌠 thank you 🌠 for taking the time to consider a contribution to Apollo! Here are some important details to follow: * ⏰ Your time is important To save your precious time, if the contribution you are making will take more than an hour, please make sure it has been discussed in an issue first. This is especially true for feature requests! * 💡 Features Feature requests can be created and discussed within a GitHub Issue. Be sure to search for existing feature requests (and related issues!) prior to opening a new request. If an existing issue covers the need, please upvote that issue by using the 👍 emote, rather than opening a new issue. * 🔌 Integrations Apollo Server has many web-framework integrations including Express, Koa, Hapi and more. When adding a new feature, or fixing a bug, please take a peak and see if other integrations are also affected. In most cases, the fix can be applied to the other frameworks as well. Please note that, since new web-frameworks have a high maintenance cost, pull-requests for new web-frameworks should be discussed with a project maintainer first. * 🕷 Bug fixes These can be created and discussed in this repository. When fixing a bug, please _try_ to add a test which verifies the fix. If you cannot, you should still submit the PR but we may still ask you (and help you!) to create a test. * 📖 Contribution guidelines Follow https://github.com/apollographql/apollo-server/blob/main/CONTRIBUTING.md when submitting a pull request. Make sure existing tests still pass, and add tests for all new behavior. * ✏️ Explain your pull request Describe the big picture of your changes here to communicate to what your pull request is meant to accomplish. Provide 🔗 links 🔗 to associated issues! We hope you will find this to be a positive experience! Open source contribution can be intimidating and we hope to alleviate that pain as much as possible. Without following these guidelines, you may be missing context that can help you succeed with your contribution, which is why we encourage discussion first. Ultimately, there is no guarantee that we will be able to merge your pull-request, but by following these guidelines we can try to avoid disappointment. -->
Thanks for the additional clarity @SimenB - didn't mean to conflate the two, @glasser worked on changing to ESM mode recently, but our tests continued to pass on the I like your suggestions to minimize the diff here so I went ahead and put these PRs together: |
ef11e67
to
c99e405
Compare
🎉 |
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to version-4, this PR will be updated.⚠️ ⚠️ ⚠️ ⚠️ ⚠️ ⚠️ `version-4` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `version-4`.⚠️ ⚠️ ⚠️ ⚠️ ⚠️ ⚠️ # Releases ## @apollo/[email protected] ### Patch Changes - [#6827](#6827) [`0c2909aa1`](0c2909a) Thanks [@glasser](https://github.com/glasser)! - Experimental support for incremental delivery (`@defer`/`@stream`) when combined with a prerelease of `graphql-js`. - [#6850](#6850) [`256f2424b`](256f242) Thanks [@renovate](https://github.com/apps/renovate)! - Expand jest peer deps to include v29 - [#6910](#6910) [`6541f92c9`](6541f92) Thanks [@trevor-scheer](https://github.com/trevor-scheer)! - Update snapshot format to future jest v29 default - [#6827](#6827) [`0c2909aa1`](0c2909a) Thanks [@glasser](https://github.com/glasser)! - Support application/graphql-response+json content-type if requested via Accept header, as per graphql-over-http spec. Include `charset=utf-8` in content-type headers. - Updated dependencies \[[`0c2909aa1`](0c2909a), [`0c2909aa1`](0c2909a)]: - @apollo/[email protected] ## @apollo/[email protected] ### Patch Changes - [#6827](#6827) [`0c2909aa1`](0c2909a) Thanks [@glasser](https://github.com/glasser)! - Experimental support for incremental delivery (`@defer`/`@stream`) when combined with a prerelease of `graphql-js`. - Updated dependencies \[[`0c2909aa1`](0c2909a), [`0c2909aa1`](0c2909a)]: - @apollo/[email protected] ## @apollo/[email protected] ### Patch Changes - [#6827](#6827) [`0c2909aa1`](0c2909a) Thanks [@glasser](https://github.com/glasser)! - Experimental support for incremental delivery (`@defer`/`@stream`) when combined with a prerelease of `graphql-js`. - [#6827](#6827) [`0c2909aa1`](0c2909a) Thanks [@glasser](https://github.com/glasser)! - Support application/graphql-response+json content-type if requested via Accept header, as per graphql-over-http spec. Include `charset=utf-8` in content-type headers. Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This PR contains the following updates:
28.x
->28.x || 29.x
28.1.8
->29.0.2
28.x
->28.x || 29.x
28.1.3
->29.0.3
28.1.3
->29.0.3
28.1.3
->29.0.3
28.0.8
->29.0.1
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Renovate will not automatically rebase this PR, because other commits have been found.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.
This PR has been generated by Mend Renovate. View repository job log here.