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

fix: Jest timer error in unit test #12230

Merged
merged 8 commits into from
Dec 6, 2024
Merged

fix: Jest timer error in unit test #12230

merged 8 commits into from
Dec 6, 2024

Conversation

NicolasMassart
Copy link
Contributor

Description

Fixes the following error message when runnning app/components/Views/QRTabSwitcher/QRTabSwitcher.test.tsx test:

ReferenceError: You are trying to access a property or method of the Jest environment after it has been torn down. From app/components/Views/QRTabSwitcher/QRTabSwitcher.test.tsx.

      at Timeout.now [as _onTimeout] (node_modules/react-native/jest/setup.js:28:41)

Related issues

Fixes: N/A

Manual testing steps

N/A

Screenshots/Recordings

N/A

Before

N/A

After

N/A

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

Fixes:
ReferenceError: You are trying to access a property or method of the Jest environment after it has been torn down. From app/components/Views/QRTabSwitcher/QRTabSwitcher.test.tsx.

      at Timeout.now [as _onTimeout] (node_modules/react-native/jest/setup.js:28:41)
@NicolasMassart NicolasMassart self-assigned this Nov 7, 2024
@NicolasMassart NicolasMassart added team-mobile-platform Mobile Platform team needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) labels Nov 7, 2024
Copy link
Contributor

github-actions bot commented Nov 7, 2024

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@NicolasMassart NicolasMassart added the No QA Needed Apply this label when your PR does not need any QA effort. label Nov 7, 2024
@NicolasMassart NicolasMassart marked this pull request as ready for review November 7, 2024 17:24
@NicolasMassart NicolasMassart requested a review from a team as a code owner November 7, 2024 17:24
@NicolasMassart NicolasMassart added Run Smoke E2E Triggers smoke e2e on Bitrise No E2E Smoke Needed If the PR does not need E2E smoke test run and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Dec 6, 2024
@NicolasMassart
Copy link
Contributor Author

Added the no e2e smoke needed as the change is only touching a unit test and it would only run smoke for nothing.

@MetaMask MetaMask deleted a comment from github-actions bot Dec 6, 2024
Copy link

sonarqubecloud bot commented Dec 6, 2024

Copy link
Member

@Gudahtt Gudahtt left a comment

Choose a reason for hiding this comment

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

LGTM!

@NicolasMassart NicolasMassart added this pull request to the merge queue Dec 6, 2024
Merged via the queue into main with commit 33c1784 Dec 6, 2024
36 checks passed
@NicolasMassart NicolasMassart deleted the fix/jest_timer branch December 6, 2024 16:55
@github-actions github-actions bot removed the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label Dec 6, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Dec 6, 2024
@metamaskbot metamaskbot added the release-7.38.0 Issue or pull request that will be included in release 7.38.0 label Dec 6, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
No E2E Smoke Needed If the PR does not need E2E smoke test run No QA Needed Apply this label when your PR does not need any QA effort. release-7.38.0 Issue or pull request that will be included in release 7.38.0 team-mobile-platform Mobile Platform team
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

5 participants