What you need to know
A test that only checks internal state can pass while users still cannot complete the task. User-centered tests are more resilient to harmless refactors and reveal missing error or empty states.
How to apply it
Render the interface, interact through accessible labels and buttons, assert the result a user sees, and cover the normal path plus one meaningful failure case. Keep fixtures representative.
Common mistake to avoid
Do not mock every function so thoroughly that the test never exercises the behavior under review. Use mocks only at external boundaries.
