Why Testing Library is not unit testing
Testing Library is useful, but rendering components and testing them through the DOM is integration testing, not unit testing.
Testing strategy, test design, and feedback loops for reliable software.
Testing Library is useful, but rendering components and testing them through the DOM is integration testing, not unit testing.
React Testing Library works best with semantic queries like role and label. Shipping data-testid to production hides accessibility problems and turns test-only markup into an accidental contract.
Code coverage shows what your tests execute. Mutation testing shows whether your tests fail when the code is wrong, and where Stryker fits.
Unit tests do not feel fragile because testing is hard. They feel fragile because our design mixes business logic and side effects.