menu
Channels
Chat
view-forward
# All channels
view-forward
# General
view-forward
# General Help
view-forward
# Angular Help
view-forward
# Cypress Help
view-forward
# DOM Help
view-forward
# React Help
view-forward
# Svelte Help
view-forward
# TestCafe Help
view-forward
# Vue Help
view-forward
Team
Posts
Members
Info

How to test react-navigation 5.x.x?

Hey, folks, could you help me on how to test native react screens/components when using react-navigation 5.x.x? because I get an error when my component has routes and I ended up crashing that part 😔 Error message: …

thumbsup
1
message-simple
14

How to trigger a onScroll event with native-testing-library

Hey guys I tried this and this is not working? const onScrollMock = jest.fn(); const scrollview = render( …

thumbsup
0
message-simple
1

Hai all, Not supported issue for lazy?

Mine "react-native-testing-library": "^1.12.0", "react-test-renderer": "^16.12.0"! Lazy_issue.PNG

thumbsup
0
message-simple
3

I notice the docs haven't been updated in a bit for react navigation

Does anyone have a good direction to head in implementing @testing-library/react-native with react navigation 5.0.0? Having trouble trying to translate from 4.0.0 docs and the next docs don't seem to help much either! Would be much appreciated!

thumbsup
0
message-simple
0

Simulate a Swipe Event - React Native

Does any one know if an api is provided to test swipe events? I didn't see it documented any where. I have a list of items and each item can we swiped to the side to expose a menu to edit or delete items. I was hoping to test this functionality in my tests with…

thumbsup
0
message-simple
0

How to get a checkbox in React Native

I have this Checkbox in one of my components: but when I try to get it using getByTestId it doesn't work and I get an error. I tried to debug the component and this is why I get when rendering the Checkbox …

thumbsup
0
message-simple
2

How might you check if an input has focus in a test?

I was trying to do something like - however, the isFocused method is not available to props like they are mentioned in the docs - https://facebook.github.io/react-native/docs/textinput#isfocused. Thanks!

thumbsup
0
message-simple
7

Found multiple elements with the testID of XYZ

Hello, I am new to Testing Library and React in general so I apologize if I am missing something simple. I have searched this error and came up with a Twitter post by Kent but it did not have any hints in to 'how' to fix this. I am trying to test that when a link/button is…

thumbsup
0
message-simple
1

Testing a disabled button

I'm using react-native-testing-library to test my RN app. I want to test that use is not able click on button which is disabled. I can confirm in UI that button is disabled but when I do fireEvent.press(getByType('button')) is doesn't recognize button is disabled and actually…

thumbsup
0
message-simple
4

How do you test an Alert?

Hi, I'm learning how to you use testing-library on a react native app and I have come across an issue, I have this alert: …

thumbsup
1
message-simple
1