How to debug unit test with MonoDevelop?

旧巷老猫 提交于 2019-12-08 16:22:18

问题


I have MonoDevelop 2.4.2 on OSX. I have a failing unit test that I would like to debug. Is there a way to do it? I found a reference on MonoDevelop mailing list but my version does not have mentioned option.

Am I missing something?


回答1:


I was able to debug a unit test library by right-clicking my "unit test project" in the "Solution Explorer" and choosing "Debug Item".

I'm running the Windows version of MonoDevelop, but the same option is available on Linux and OSX versions.




回答2:


On OSX monodevelop 3.0.4 this is now: Right click on unit test -> run with -> "Mono soft debugger".

You can add breakpoints using the 'run' menu too, if you need to.




回答3:


I am running Xamarin Studio Community. @Kedde's answer does not work for the NUnit test in this version of the IDE. I created a Console project that runs unit tests. I am able to debug by stepping into the console methods.



来源:https://stackoverflow.com/questions/4868276/how-to-debug-unit-test-with-monodevelop

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