Hard-Coded Mock Objects vs Mocking Framework

后端 未结 6 1955
悲&欢浪女
悲&欢浪女 2020-12-16 19:18

I\'m curious as to what method people like to use for mocking and why. The two methods that I know of are using hard coded mock objects and a mocking framework. To

6条回答
  •  离开以前
    2020-12-16 19:46

    I tend to write stubs and mocks by hand, first. Then if it can be easily expressed using a mock object framework, I rewrite it so that I have less code to maintain.

提交回复
热议问题