"ToMethodObject" is a Visual Studio Extension designed to simplify and automate the process of refactoring code, specifically the "Replace Method with Method Object" refactoring pattern.
Features
Automated Refactoring: With just a few clicks, you can refactor your code using the "Replace Method with Method Object" pattern. This extension automatically creates a new Method Object class for you.
Easy Testing: The extension makes it easier to write tests for your code by eliminating unnecessary dependencies.
Improved Code Quality: By making your code more testable, this extension helps improve the overall quality and maintainability of your code.
How to Use
Highlight the static method you want to refactor.
Click on the refactoring icon and select "Extract To Method Object".
The extension will automatically create a new Method Object class and update the original method to call the new Method Object class.
Conclusion
Make your tests easy to write and write the easy tests with the ToMethodObject refactoring extension!