Testing · Junior · Question 41 of 78
What is the main principle of Testing Library?
- ✓Correct answer: “The more your tests resemble the way your software is used, the more confidence they can give you”
- 2“Test every function separately”
- 3“A component test should check its state and props”
Explanation
So tests find elements the way a user does - by role, label and text - and interact through events.