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

[EASI-3934] Dependency Updates --- Round 2 #965

Merged
merged 18 commits into from
Feb 22, 2024

Conversation

garyjzhao
Copy link
Contributor

@garyjzhao garyjzhao commented Feb 20, 2024

EASI-3934

Changes and Description

  • Updated the following dependencies
    • react-idle-timer
    • @testing-library/jest-dom
    • @testing-library/react
      • Kept this to version 12.1.5, since v13+ drops support for React v17 and earlier
    • @testing-library/user-event
      • notable breaking changes introduced. see below

Changes introduced in updating @testing-library/user-event

As of v14, user event introduced a new way to invoke userEvent. Long story short, they recommend setting up a setup util function before the component is rendered. It is documented here: https://testing-library.com/docs/user-event/intro/

-import userEvent from '@testing-library/user-event'
+import setup from 'utils/testing/setup';

-userEvent.type(getByTestId('test-note'), 'Test Note');
+await user.type(getByTestId('test-note'), 'Test Note');

How to test this change

  1. yarn install
  2. yarn test
  3. verify no tests are breaking

PR Author Review Checklist

  • Met the ticket's acceptance criteria, or will meet them in a subsequent PR.
  • Added or updated tests for backend resolvers or other functions as needed.
  • Added or updated client tests for new components, parent components, functions, or e2e tests as necessary.
  • Updated the Postman Collection if necessary.

PR Reviewer Guidelines

  • It's best to pull the branch locally and test it, rather than just looking at the code online!
  • Check that all code is adequately covered by tests - if it isn't feel free to suggest the addition of tests.
  • Always make comments, even if it's minor, or if you don't understand why something was done.

@garyjzhao garyjzhao changed the title [EASI-3934] Dependency Updates round2 [EASI-3934] Dependency Updates --- Round 2 Feb 20, 2024
@garyjzhao garyjzhao marked this pull request as ready for review February 20, 2024 19:28
@garyjzhao garyjzhao requested a review from a team as a code owner February 20, 2024 19:28
@garyjzhao garyjzhao requested review from patrickseguraoddball and removed request for a team February 20, 2024 19:28
Copy link
Contributor

@patrickseguraoddball patrickseguraoddball left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG!

@garyjzhao garyjzhao merged commit 330133d into main Feb 22, 2024
11 checks passed
@garyjzhao garyjzhao deleted the EASI-3934/dependency-updates-round2 branch February 22, 2024 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants