WorkFlow Unit Testing

寵の児 提交于 2019-12-04 20:29:49

问题


How to unit test the windows workflows?


回答1:


K. Scott Allen has posted this, which provides an approach to unit testing custom activities (although he says that he is not satisfied). A similar approach is presented by Ron Jacobs here and here.

Another approach is presented by Maurice here and here (he uses TypeMock as Will already mentioned).




回答2:


Microsoft.Activities.UnitTesting.

A library of helper classes and activities designed to make unit testing of workflows easier.

Looks like there's a Channel 9 video for it on the downloads page, too.




回答3:


MS dropped the ball on making workflows easily mockable and testable. If you want to do thorough tests on your custom activities you'll need to purchase a mocking framework that can mock sealed types such as TypeMock. Otherwise, you'll have to write your code around the limitations of Workflow.



来源:https://stackoverflow.com/questions/182740/workflow-unit-testing

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!