PART I: The Mechanics of Change
Four Reasons to Change Software
Chapter 2: Working with Feedback
The Legacy Code Change Algorithm
Chapter 3: Sensing and Separation
Chapter 6: I Don’t Have Much Time and I Have to Change It
Chapter 7: It Takes Forever to Make a Change
Chapter 8: How Do I Add a Feature?
Chapter 9: I Can’t Get This Class into a Test Harness
The Case of the Irritating Parameter
The Case of the Hidden Dependency
The Case of the Construction Blob
The Case of the Irritating Global Dependency
The Case of the Horrible Include Dependencies
The Case of the Onion Parameter
The Case of the Aliased Parameter
Chapter 10: I Can’t Run This Method in a Test Harness
The Case of the “Helpful” Language Feature
The Case of the Undetectable Side Effect
Chapter 11: I Need to Make a Change. What Methods Should I Test?
Chapter 12: I Need to Make Many Changes in One Area.
Judging Design with Pinch Points
Chapter 13: I Need to Make a Change, but I Don’t Know What Tests to Write
A Heuristic for Writing Characterization Tests
Chapter 14: Dependencies on Libraries Are Killing Me
Chapter 15: My Application Is All API Calls
Chapter 16: I Don’t Understand the Code Well Enough to Change It
Chapter 17: My Application Has No Structure
Telling the Story of the System
Chapter 18: My Test Code Is in the Way
Chapter 19: My Project Is Not Object Oriented. How Do I Make Safe Changes?
Taking Advantage of Object Orientation
Chapter 20: This Class Is Too Big and I Don’t Want It to Get Any Bigger
Chapter 21: I’m Changing the Same Code All Over the Place
Chapter 22: I Need to Change a Monster Method and I Can’t Write Tests for It
Tackling Monsters with Automated Refactoring Support
The Manual Refactoring Challenge
Chapter 23: How Do I Know That I’m Not Breaking Anything?
Chapter 24: We Feel Overwhelmed. It Isn’t Going to Get Any Better
PART III: Dependency-Breaking Techniques
Chapter 25: Dependency-Breaking Techniques
Extract and Override Factory Method
Replace Function with Function Pointer