News for hackers. Stuff that matters.
Re:Is it a Good Idea to Write Tests for Legacy Code? by jaggederest on Wednesday November 20, 2013 @06:32AM (#6767439)
Honestly it depends entirely on the expected lifetime of the changed code and the complexity of the changes required.

If a particular application is just milking out another year or two until it's replaced, it's probably not worth erecting unit test scaffolding around the entire app. Sometimes it's safer to just change a couple constants and do a smoke test than to really get into it.

That said, my experience was that it was immeasurably helpful in breaking apart and working with older code - just taking a portion of my time devoted solely to writing unit tests helped my understanding beyond what you'd expect.

There are no comments on this comment yet.