Book ReviewWorking Effectively With Legacy Code
Working Effectively with Legacy Code is a book that should be a mandatory reading for anyone who is interested in coding for a living. I don't deal with many legacy systems at the present (except for NQA, of course :-) ) and still this book has been a fountain of knowledge about techniques, tips and tricks.
This is not a book about pretty code, it's a book about ugly code and all the myrad ways you can abuse design pricipals and good coding practices. What it does is show a set to systematically take a legacy code* and break down the dependencies so you can write tests for the code. The moment you've tests, you can move forward. Until you've tests, you're in a position where all you can do is "Edit & Pray" or... you can write tests.
I've had recent experiance with developing applications in a TDD from the start (Rhino Mocks) and converting a legacy application to TDD (NQA). I can't rave enough about how much easier it is to make a change in Rhino Mocks because of those tests. When I adapted Rhino Mocks to run on .Net 2.0 I'd broken just about every part of the application because I didn't consider what the change from Hashtable to Dictionary<T> would do when there is no item in the dictionary. Because I'd tests, it was literaly the work of a minute to find the problem and fix it.
One thing to note about this book, it took me over two months to read it. Like Xp Explained 2nd Ed. I just can't seem to read it for any length of time without starting to feel a sudden need to code something. Very productive for my projects, less so for my reading backlog.
* Legacy Code == Code without tests.
More posts in "Book Review" series:
- (05 Nov 2009) The Wheel of Time – The Gathering Storm
 - (11 Aug 2009) Yellow Eyes
 - (24 Jul 2009) Watch on the Rhine
 - (23 Jul 2009) By Heresies Distressed
 - (23 Jul 2008) By Schism Rent Asunder
 - (04 Oct 2007) Making Money
 - (30 Sep 2007) Empire of Ivory
 - (08 Sep 2007) Empire Of Man
 - (01 Sep 2007) March Upcountry
 - (21 Feb 2007) Programming WCF Services
 - (09 Feb 2007) Windows Developer Power Tools
 - (25 Sep 2006) Old Man's War
 - (03 Sep 2006) His Majesty's Dragon / Throne of Jade / Black Powder War
 - (30 Aug 2006) Applying Domain-Driven Design and Patterns
 - (18 Aug 2006) Dzur
 - (15 Aug 2006) When Darkness Falls
 - (22 Apr 2006) Data Binding with Windows Forms 2.0
 - (17 Oct 2005) Knife Of Dreams
 - (28 Aug 2005) Working Effectively With Legacy Code
 - (25 Jul 2005) Harry Potter and the Half-Blood Prince
 - (14 Jul 2005) Sword of Ice
 - (14 Jul 2005) Vows & Honor Trilogy
 - (14 Jul 2005) The Mage Storms Trilogy
 - (14 Jul 2005) Winds of Change
 - (10 Jul 2005) Winds of Change
 - (09 Jul 2005) Winds Of Fate
 - (08 Jul 2005) Burning Water
 - (08 Jul 2005) By The Sword
 - (06 Jun 2005) Developer To Designer
 - (05 Jun 2005) The Last Herald Mage
 - (01 Jun 2005) Arrow's Fall
 - (01 Jun 2005) Arrow's Flight
 - (27 Apr 2005) Domain Driven Desing
 - (01 Apr 2005) Exile's Valor
 - (18 Jan 2005) Alta
 - (16 Jan 2005) Coding Slave
 - (13 Jan 2005) Hibernate In Action
 - (25 Oct 2004) In Search of Stupidity
 


Comments
Comment preview