Skip to content
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

Upgrade testing-library packages #8406

Merged
merged 5 commits into from
May 4, 2020
Merged

Upgrade testing-library packages #8406

merged 5 commits into from
May 4, 2020

Conversation

gnapse
Copy link
Contributor

@gnapse gnapse commented Jan 31, 2020

jest-dom's latest major version has its type definitions moved to DefinitelyTyped (see testing-library/jest-dom#123). This make it so the TypeScript definitions work automatically without config. This PR upgrades the version referenced in the template so that newly generated projects get the newest version right from the start.

The newest jest-dom version also makes it so that the main module takes care of extending expect, so this PR includes the following change where appropriate (though the usual way still works):

-import '@testing-library/jest-dom/extend-expect';
+import '@testing-library/jest-dom';

This PR also takes the liberty to upgrade the actual dev dependency of create-react-app itself. Ran the tests and it all worked. Hope that's ok too.

@ianschmitz ianschmitz closed this May 4, 2020
@ianschmitz ianschmitz reopened this May 4, 2020
@ianschmitz ianschmitz added this to the 4.0 milestone May 4, 2020
@ianschmitz ianschmitz changed the title Upgrade @testing-library/jest-dom to its latest major version Upgrade testing-library packages May 4, 2020
@ianschmitz ianschmitz merged commit 5d437b8 into facebook:master May 4, 2020
@gnapse gnapse deleted the upgrade-jest-dom-version branch May 4, 2020 13:08
@lock lock bot locked and limited conversation to collaborators May 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants