github callstack/react-native-testing-library v13.0.0-rc.0

pre-release6 days ago

13.0.0-rc.0 (2024-12-08)

Important Changes

  • Enabled concurrent rendering by default
  • Automatically extend Jest matchers, you no longer need to import @testing-library/react-native/extend-expect. Importing @testing-library/react-native will be enough.
  • remove host component name auto-detection. Test should run faster.

Removed

  • *ByA11yState queries have been removed use *ByRole queries or toHaveAccessibilityState matcher instead
  • *ByA11yValue queries have been removed use *ByRole queries or toHaveAccessibleValue matcher instead
  • Removed support for React 16 & 17. Supports React 18 and 19.
  • Removed debug.shallow method
  • Removed @testing-library/react-native Jest preset (useful for React 17). Just use regular react-native Jest preset.

Other changes (should have no visible effects):

  • new implementation of flushMicrotaskQueue
  • slightly different way to calculate a11y labels
  • uses React's implementation of act instead of React Test Renderer's

Don't miss a new react-native-testing-library release

NewReleases is sending notifications on new releases.