灵感菇

AI 技能的自然生态,你的一句话,蔓延出无限连接。

返回搜索

软件工程 / 诊断修复

generate-testability-wrappers

generate-testability-wrappers

安装量 145GitHub Stars 1,709更新时间 2026年5月16日

描述

Generate wrapper interfaces and DI registration for hard-to-test static dependencies in C#. Produces IFileSystem, IEnvironmentProvider, IConsole, IProcessRunner wrappers, or guides adoption of TimeProvider and IHttpClientFactory. USE FOR: generate wrapper for static, create IFileSystem wrapper, wrap DateTime.Now, make static testable, make class testable, create abstraction for File.*, generate DI registration, TimeProvider adoption, IHttpClientFactory setup, testability wrapper, mock-friendly interface, mock time in tests, create the right abstraction to mock, how to mock DateTime, test code using File.ReadAllText, what abstraction for Environment, how to make statics injectable, adopt System.IO.Abstractions, make file calls testable. DO NOT USE FOR: detecting statics (use detect-static-dependencies), migrating call sites (use migrate-static-to-wrapper), general interface design not about testability.

安全审计

使用前的风险提示

未审计

规则审计

未审计
更新 1年1月1日

智能审计

未审计
更新 1年1月1日
designuigeneratetestabilitywrapperswrapperinterfacesandregistrationforhardtest