All resources
Modernization30 August 2026·5 min read

Characterization tests: lock down what the old system does before you change it

When there are no tests and no specification, record actual behaviour first. Then change with confidence.

Legacy code often has no reliable tests, so nobody can say what 'correct' means. A characterization test records what the system does today, right or wrong, so you can tell whether a change altered it.

Steps

  • Collect real inputs and the outputs the current system produces.
  • Turn them into automated comparisons.
  • Include unusual cases: month-end, rounding, empty fields, large values.
  • Flag differences for a human decision: bug in the old system, or behaviour to preserve?

AI can help generate candidate test cases from code and logs. A person still decides which behaviour is intended.

Related capability

This is what our Legacy System Modernization practice is built around.

See how it's scoped