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

feat: migrate example tests to @testing-library/react-native #101

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mdjastrzebski
Copy link

@mdjastrzebski mdjastrzebski commented Jan 29, 2025

Summary:

As React Test Renderer is now deprecated, it make sense to switch example test from RTR to React Native Testing Library which is recommended for RN env.

While RNTL currently uses RTR under the hood, there are works in progress to replace internal RTR usage with alternative supported test renderer. Migrating tests now, direct users to future-proof testing solution.

Replaces #77

Changelog:

GENERAL CHANGED - Migrate example test from deprecated React Test Renderer to React Native Testing Library (@testing-library/react-native).

Test Plan:

Run tests included in the template directory.

Copy link
Collaborator

@szymonrybczak szymonrybczak left a comment

Choose a reason for hiding this comment

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

Nice 👌 Thanks @mdjastrzebski!

Copy link
Member

@cortinico cortinico left a comment

Choose a reason for hiding this comment

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

@@ -24,6 +24,7 @@
"@react-native/eslint-config": "0.78.0-main",
"@react-native/metro-config": "0.78.0-main",
"@react-native/typescript-config": "0.78.0-main",
"@testing-library/react-native": "^13.0.1",
"@types/jest": "^29.5.13",
"@types/react": "^19.0.0",
"@types/react-test-renderer": "^19.0.0",
Copy link
Member

Choose a reason for hiding this comment

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

can you remove this and line 34 also?

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.

3 participants