我是JustMock模拟框架的新手,我正在尝试模拟一个私有方法。我完全知道对私有方法进行单元测试通常是一种糟糕的做法,但在这种情况下,我别无选择。我一直在看官方文档(),但似乎什么都不起作用。下面是我的示例代码:using Telerik.JustMock;
{ {mockeClass.useA();}Run-time exception (line 21): The type initializer
我正在用C#、.NET Framework4.7、Nunit 3.8.0和JustMock Lite 2017.2.821.1开发一个TDD测试。Source=Telerik.JustMock at Telerik.JustMock.Core.Context.MockingContext.get_CurrentRepository() at Telerik.JustMock
我在单元测试中使用Telrik JustMock模拟。在本地它工作得很好,但当我尝试将它与基于Asp.net构建模板的VSTS构建集成时,它以错误告终。(MemberInfo成员) 2017-08-04T08:24:12.0462606Z at Telerik.JustMock.Core.MocksRepository.InterceptStatics2017-08-04T08:24:12.0462606Z at Telerik.JustMock.Mock.[T](Func1 guardedAction) 2017-08-04T08:24: