NUnit - Monodevelop 集成

发布于 2024-12-26 10:34:30 字数 1429 浏览 2 评论 0原文

当我想在 Monodevelop 2.6(Ubuntu 默认存储库)和 NUnit-Integration(apt-get install monodevelop-nunit)中启动单元测试时,我总是收到以下错误。

即使我将项目编译为 .Net 3.5 (x86) 或 .Net 4.0(任何 CPU)或任何其他组合,我也会收到以下错误。

我不明白这一点,因为“nunit-console BurnSystems.Tests.dll”工作正常。

这完全没问题,但我需要调试器来检查测试失败的根本原因在哪里。像 Visual Studio 中那样的“调试外部应用程序”似乎在 MonoDevelop 中不可用。


Error - 20:45:31 - System.NullReferenceException: Object reference not set to an instance of an object

Server stack trace: 
  at NUnit.Util.DomainManager.CreateDomain (NUnit.Core.TestPackage package) [0x00000] in :0 
  at MonoDevelop.NUnit.External.ExternalTestRunner.GetRunner (System.String assemblyPath) [0x00000] in :0 
  at MonoDevelop.NUnit.External.ExternalTestRunner.Run (IRemoteEventListener listener, ITestFilter filter, System.String path, System.String suiteName, System.Collections.Generic.List`1 supportAssemblies) [0x00000] in :0 
  at (wrapper managed-to-native) System.Runtime.Remoting.RemotingServices:InternalExecute (System.Reflection.MethodBase,object,object[],object[]&)
  at System.Runtime.Remoting.RemotingServices.InternalExecuteMessage (System.MarshalByRefObject target, IMethodCallMessage reqMsg) [0x00000] in :0 

Exception rethrown at [0]: 

  at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke (System.Runtime.Remoting.Proxies.RealProxy rp, IMessage msg, System.Exception& exc, System.Object[]& out_args) [0x00000] in :0 

when I'd like to start a unittest within Monodevelop 2.6 (Ubuntu default repository) and NUnit-Integration (apt-get install monodevelop-nunit), I get always the following error.

Even if I compile my projects as .Net 3.5 (x86) or .Net 4.0 (Any CPU) or any other combination, I get the following error.

I do not understand this because 'nunit-console BurnSystems.Tests.dll' is working perfectly.

This would be perfectly OK, but I need the debugger to check where the root cause for a failed test is. "Debug external application" like in Visual Studio seems not to be available in MonoDevelop.



Error - 20:45:31 - System.NullReferenceException: Object reference not set to an instance of an object

Server stack trace: 
  at NUnit.Util.DomainManager.CreateDomain (NUnit.Core.TestPackage package) [0x00000] in :0 
  at MonoDevelop.NUnit.External.ExternalTestRunner.GetRunner (System.String assemblyPath) [0x00000] in :0 
  at MonoDevelop.NUnit.External.ExternalTestRunner.Run (IRemoteEventListener listener, ITestFilter filter, System.String path, System.String suiteName, System.Collections.Generic.List`1 supportAssemblies) [0x00000] in :0 
  at (wrapper managed-to-native) System.Runtime.Remoting.RemotingServices:InternalExecute (System.Reflection.MethodBase,object,object[],object[]&)
  at System.Runtime.Remoting.RemotingServices.InternalExecuteMessage (System.MarshalByRefObject target, IMethodCallMessage reqMsg) [0x00000] in :0 

Exception rethrown at [0]: 

  at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke (System.Runtime.Remoting.Proxies.RealProxy rp, IMessage msg, System.Exception& exc, System.Object[]& out_args) [0x00000] in :0 

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文