I was explaining some of the governing principals to a colleague today...
- "First you have to get your legacy code into a test harness, then you can safely alter it."
- "OK."
- "However, you'll need to alter it before you can do that."
- "Huh?"
I have come to the conclusion that Working with Legacy code does not so much involved harnesses as muzzles. It is akin to Muzzling an Angry Dog. First, you have to sneak up to it, from behind, without making any noise or disturbing it's environment. Then, once the muzzle is safely on you can relax and poke it as much as you like. From now on, our estimates will have a 'Dog Muzzling' factor added to them.
[And, no, I do not condone taunting any dog, angry or otherwise.]