Sprout techniques involve creating new methods or classes to encapsulate additional functionality or refactored behavior. These techniques help to safely introduce changes while preserving existing behavior, minimizing risks, and improving testability. In this course we will use sprout techniques with methods and objects to refactor or expand capabilities.
Overview
Syllabus
- Lesson 1: Sprout Method - Reducing Risk of Adding New Features
- Lesson 2: Sprout Method - When a Method Does Too Much
- Lesson 3: Wrap Method - Safely Adding New Behaviors
- Lesson 4: Sprout Class - When Classes Do Too Much
- Lesson 5: Sprout Class - When New Shouldn't Affect Old
- Lesson 6: Wrap Class - Expanding Whole Class Behavior