Understanding automated testing
There are different forms of automated testing. The following forms of automated testing are the most common ones and will be covered in this chapter:
- Unit tests: Unit tests cover the smallest parts of your business logic, such as single functions.
- Integration tests: This form of testing works very similar to unit tests in React Native, but it covers multiple pieces of your business logic and tests whether the integration of these parts works as expected.
- Component tests: These tests cover your React Native UI components and check whether they do what they are expected to do. You can also check for (unexpected) changes in your components with this form of testing.
- End-to-end tests: This form of testing simulates end user behavior and checks whether your whole application behaves like it is expected to do.
To get the most out of automated testing, you should implement all four types of tests. All of them cover different areas...