Skip to main content

Seam Type Selector

Select the right seam type (Preprocessor / Link / Object) for breaking a dependency in legacy code. Use whenever a developer needs to substitute behavior for testing without editing in place, is choosing between dependency-injection strategies in an existing codebase, or asks 'how do I intercept this call in a test' / 'how do I fake this library' / 'how do I test around this hard-coded dependency'. Activates for 'seam', 'test seam', 'substitution point', 'dependency injection for legacy code', 'mock this without DI framework', 'C++ testing', 'linker-level fake', 'preprocessor substitution', 'polymorphic substitution', 'enabling point'.

Install

1. Add marketplace
/plugin marketplace add bookforge-ai/bookforge-skills
2. Install plugin
/plugin install working-effectively-with-legacy-code@bookforge-skills
3. Use the skill
/seam-type-selector
CC-BY-SA · Open sourceGitHub

What You'll Need

ReadGrepEdit (optional)

Source Book

Working Effectively with Legacy Code cover

Working Effectively with Legacy Code

Michael C. Feathers