Interface / Abstract Class Coding Standard

后端 未结 5 841
礼貌的吻别
礼貌的吻别 2021-02-09 06:01

I spotted a proposed C# coding-standard which stated \"Try to offer an interface with all abstract classes\". Does someone know the rationale for this?

5条回答
  •  没有蜡笔的小新
    2021-02-09 06:18

    Without looking at the original article, I would guess that the original author is suggesting it for testability and allow easy mocking of the class with tools like MoQ, RhinoMocks etc.

提交回复
热议问题