Regression Testing
Regression testing checks that a change has not unintentionally broken behavior that previously worked.
Download Markdown (.md)Soroush’s Product Wiki · https://wiki.soroush.uk/topic/regression-testing/
01What it means
Regression testing repeats or extends checks of existing behavior after code, configuration, dependency, or environment changes. It is a testing purpose rather than a particular test level: unit, integration, and end-to-end checks can all provide regression coverage. Retesting a repaired defect confirms the fix; regression testing also examines collateral effects.[1][2]
02Why it matters
Shared code makes seemingly small changes capable of damaging distant features. Deliberate regression coverage protects important customer tasks and gives teams evidence about the impact of maintenance and refactoring.
03When to use it
Use it after changes with plausible effects on established behavior, especially shared libraries, pricing rules, and migrations. Select coverage using risk and dependencies. For intentionally changed requirements, update expectations rather than treating every difference as a defect.
04How it works
- Identify changed behavior, affected dependencies, and critical existing workflows.
- Choose relevant established checks plus tests for newly discovered failure cases.
- Run the checks at the narrowest useful levels.
- Investigate differences against intended requirements and isolate real regressions.
- Update coverage and remove obsolete or redundant assertions after review.
05A practical example
A coupon fix resolves a discount rounding bug. The team retests the defect and also runs existing refund, tax, and invoice checks because they share the pricing function. A refund mismatch blocks release even though the original coupon case now passes.
06Where it breaks
Regression suites only protect known expectations and can preserve outdated assumptions. Large indiscriminate suites consume maintenance time and may hide flaky tests. They complement exploration and new-feature validation rather than replacing them.
Common mistakes
- Retesting only the reported bug and ignoring shared dependencies.
- Updating failed expected values without checking whether behavior is wrong.
- Keeping obsolete checks that enforce requirements the team intentionally changed.
07Sources
- What is regression testing?IBM · Technical guidanceWhat is regression testing?
- Regression Testing: Definition, How it worksBrowserStack · Technical guidanceRegression Testing: Definition, How it works