1 / 6

Refactoring Towards Sanity

Refactoring Towards Sanity. Robert Reppel. ( Sample code is at http ://robertblogs.wordpress.com / ). Why Refactor ?. To get better at fixing bugs To be able to add new features faster. (Arguably) there is no other reason …. . ( Sample code is at http ://robertblogs.wordpress.com / ).

kizzy
Download Presentation

Refactoring Towards Sanity

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Refactoring Towards Sanity Robert Reppel ( Sample code is at http://robertblogs.wordpress.com/ )

  2. Why Refactor? • To get better at fixing bugs • To be able to add new features faster. • (Arguably) there is no other reason …. ( Sample code is at http://robertblogs.wordpress.com/ )

  3. What to Refactor • The minimum we can get away with. • The maximum we can sell to The Man. (???) • “The Big Re-Write” is: • Frustrating (for the business) • Not always better than the original (???)

  4. What We’ll Do • Sprout • Wrap • Refactor “When you need to add a new feature to a system and it can be formulated completely as new code, write it in a new method …. At least write tests for the new code … ” -- Michael Feathers … and writing tests, of course …

  5. Real – World Sprout: • Real Estate Conveyancing • Letters for lawyers, etc. need to contain standard phrases for deposit trust amounts, etc. • Different provinces, different conveyancing methods, different requirements. • Letters as Crystal Reports fed by Stored Procedures. (… which contain the business rules … )

  6. Sources / Reading • “Refactoring To Patterns” – Joshua Kerievsky • “Working Effectively With Legacy Code” – Michael Feathers @robertreppel robertblogs.wordpress.com

More Related