2013-06-27 175 views
0

我的團隊正在使用Moq作爲測試框架。由於我們需要測試一些http對象,尤其是會話,我們探索了更多選項,並找到了一個名爲MVCContrib的好庫,它在安裝時下載了RhinoMocks。當試圖從MVCContrib調用方法時,出現此錯誤:DataCacheClients錯誤,可能是什麼原因?

Test method uBetPro.UI.Web.Tests.AccountController.AccountControllerTests. .Login_CorrectCredentials_AuthenticationSuccess_ReturnsValidLicense threw exception: System.Configuration.ConfigurationErrorsException: Configuration system failed to initialize ---> System.Configuration.ConfigurationErrorsException: Unrecognized configuration section
dataCacheClients. (C:\Users\Shogun\AppData\Local\Temp\TestResults\Shogun 2013-06-27
15_23_17\Out\uBetPro.UI.Web.Tests.DLL.config line 27)

什麼可能導致這種情況?如果有辦法解決這個問題,我會很高興,但是我的常識意味着兩個不同的測試框架不能在同一個項目中運行,這是否合理?

回答

0

看來,你在線路上有一個問題,在您的uBetPro.UI.Web.Tests.DLL.config 27

我會假設你已經得到的東西,你有沒有嘲笑了正確和它試圖從配置文件中讀取

如果這是模擬框架之間的衝突,我希望在運行測試之前看到編譯時錯誤

相關問題