Adding Component Test Coverage with React Native Testing Library, part 2

Опубликовано: 15 Июнь 2026
на канале: CodingItWrong
1,438
19

In this week's stream we:

Test an ErrorMessage component to attempt to ensure it doesn't render anything when there is no error message
Tell our code coverage tool that we don't want to unit test a file that doesn't have any logical branches
Test a custom React Navigation navbar to ensure buttons function and conditionally appear correctly
Test a branch that wasn't covered by our "deep" integration tests by handling an edge case