Filter
Exclude
Time range
-
Near
🦉 Using @jotaijs state management and want to test it with #ReactNativeTestingLibrary? We’ve got you covered! @vanGalilea has written a Cookbook recipe just for this case 🙌 Check it out and make your testing smoother! callstack.github.io/react-na…
1
2
22
723
🦉 I've just published the 2nd recipe for the #ReactNativeTestingLibrary Cookbook 🎉 💡 It explain when, why and how to use async tests when using RNTL callstack.github.io/react-na…
3
3
38
2,023
🚀 Announcing the #ReactNativeTestingLibrary Cookbook initiative! 📖✨ We're compiling best practices, tips & tricks, and ready-to-use recipes for the RNTL community. 🍲👩‍💻👨‍🔧 Got a recipe to share? Contribute and help us create something amazing! 🙌 🔗 More details: github.com/callstack/react-n…

3
8
63
3,999
⚛️🦉 When using #ReactNativeTestingLibrary, I use this query as a default: getByRole("role", { name: "name" }) Here's why: 🔹 get - I want exactly one matching element 🔹 byRole name - I want to get an element matching both a role (e.g., "button") and a name (e.g., "Next")
1
9
330
⚛️🦉 #ReactNativeTestingLibrary with ver. 12.4.0 has achieved its main dev goals: 🔹 Introduction of User Event API 🔹 Migration of Jest matchers to RNTL 🏁 We do not plan more large features in v12. 📖 Our next focus will be improving the documentation and examples.
2
2
10
1,327
⚛️🦉 #ReactNativeTestingLibrary tip. If your query cannot find an element: 1️⃣ Use screen.debug() to inspect the element tree 2️⃣ Use `includeHiddenElements: true` query option to detect hidden elements. callstack.github.io/react-na…

10
520
⚛️🦉 In #ReactNativeTestingLibrary each query consists of two key components: 🔹 Variant: `get`, `query`, ... 🔹 Predicate: `*ByRole`, `*ByText`, ... 💡Predicate describes the specific criteria used to find matching elements. 📋 Quick summary of available predicates:
1
13
999
⚛️🦉 Using proper #ReactNativeTestingLibrary query variants helps to better express the test's intent. 💡 Query variants also serve as implicit assertions on number of matched elements. 📋 General guidelines for idiomatic query variants:
1
17
1,585
⚛️🦉 #ReactNativeTestingLibrary offers six query variants, here is how they compare:
1
1
19
1,159
BTW We've released #ReactNativeTestingLibrary v12.3.0 yesterday, just in time for #ReactNativeEU ❤️🫶 It provides support ARIA web accessibility props (role & aria-*) 🙈 github.com/callstack/react-n…
6
32
1,368
💡 #ReactNativeTestingLibrary #TipOfTheDay Most of RNTL queries accept TextMatch = string | RegExp as first argument. RegExp is the flexible option while string matcher uses case-sensitive full string equality by default. You can enable case-insensitive substring matching using the { exact: false } option. This is relevant for most of the RNTL queries: - getByRole - getByText - getByLabelText - getByHintText - getByPlaceholderText - getByDisplayValue - getByTestId
4
17
1,410
💪 Ever wanted to contribute to an Open Source project? I've created some relatively easy tasks for #ReactNativeTestingLibrary Jest Native matchers migration that could get you on track with that: github.com/callstack/react-n…

1
9
30
3,266
I've create a #ReactNativeTestingLibrary API proposal for User Event scroll interaction. 💬 Join the discussion to help us decide on the best API 👇 github.com/callstack/react-n…

1
13
2,284
📖 TIL do not use "yarn pack"/"yarn publish" with package.json "files" containing both inclusion & exclusion matchers. The exclusion matcher is applied to all files and not only to the ones passing the positive matchers first! Basically that puts most of the repo files in the NPM package.🤦‍♂️ Anyway #ReactNativeTestingLibrary v12.2.2 is out 🎉 This time not including website, example apps, etc in the NPM package.
3
1
10
1,013
🚡🗻 Just released #ReactNativeTestingLibrary v12.2.1! It fixes a small omission from the initial User Event API: ✳️ clear() function for clearing the content of a TextInput 💡 UserEvent type() function appends text to given TextInput, so you need to call clear() to actually replace it.
8
45
2,847
💡 #ReactNativeTestingLibrary #TipOfTheDay: In order for *ByRole queries to work, the matched element needs to be an accessibility element. When element is accessibility element? 1. Text, TextInput and Switch are these by default 2. Host View needs to have accessible prop set 3. Some RN components like Pressable & TouchableOpacity automatically render host View with accessible prop This matches RN iOS/Android runtime behavior, where Views without accessible prop are ignored by screen reader. 👇
6
26
3,565
🌇🌁 User Event VC pitch 😉 - Question for you: what's a better than Fire Event API sending only one event? - Answer for you: User Event API sending a sequence of 20 events for one user action. #ReactNativeTestingLibrary #SiliconValley
1
4
433