WhoBuilt

How much can you test with RNTester E2E?

Sep 5, 2023· 4 min· 302 views·Watch on YouTube

Speaker

Mateusz of Callstack explains what RNTester end-to-end tests can cover and how the React Native team is building its test suite.

Test critical component paths

Mateusz says RNTester can cover critical positive and negative paths for React Native components. It helps confirm components work in isolation within the environment React Native provides.

Test integrations in your app

RNTester cannot account for every way an application might wrap or combine components, or connect them to data. Teams should test those integrations in their own apps as well.

Prioritize common usage

Mateusz says complex combinations and edge cases are hard to predict and automate. Covering a small fraction of expected usage with a large share of tests can take disproportionate effort.

Build out the RNTester suite

The team has set up end-to-end testing in the React Native repository, with tests running on every commit and pull request. At the time of the discussion, only one test had been written, and one person was working full-time on adding tests; the team planned an umbrella issue for contributors.

Takeaways

  • Use RNTester to check critical component paths in isolation.
  • Add app-level tests for wrappers, combinations, and data communication.
  • Prioritize expected usage before investing heavily in rare edge cases.
  • A working test pipeline can be in place before the test suite is complete.
  • Contributors can help expand the suite through the planned umbrella issue.

Mentioned in this talk

Search inside this talk

What was claimed 4

  • feature
    RNTester: Tests critical positive and negative paths through React Native components
    “We can test mostly everything critical”
    YouTube
    Unverified1 source· Talk
  • metric
    RNTester: One test written at the time of the talk
    “We only have one for, I don't know, the button component or something”
    YouTube
    Unverified1 source· Talk
  • feature
    End-to-end testing: Tests run on every commit and pull request
    “The tests run on every commit and every pull request”
    YouTube
    Unverified1 source· Talk
  • feature
    RNTester: Provides a working end-to-end test setup in the React Native repository
    “we've finished the initial phase of introducing end-to-end tests to RNTester”
    YouTube
    Unverified1 source· Talk

Related talks

How much can you test with RNTester E2E?, Mateusz · WhoBuilt