如何运行在Web项目正在调试的同时测试? [英] How to run a test at the same time a web project is being debugged?

查看:149
本文介绍了如何运行在Web项目正在调试的同时测试?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在一些我们有ASP.NET/WCF web项目和一个测试项目的解决方案。有些测试使用针对ASP.NET开发的Web服务器上运行的http://本地主机:端口/ ... 。在VS2010而ASP.NET/WCF网项目正在调试,测试运行可能进行的测试,如果有在Web项目中的任何断点,调试器会打破执行。这似乎已被禁用/在VS2012中删除。

In some of the solutions we have ASP.NET/WCF web project and a test project. Some of the tests run against ASP.NET development web server using http://localhost:port/.... In VS2010 while the ASP.NET/WCF web project was being debugged, the test runner could run the tests and if there were any breakpoints in web project, the debugger would break the execution. This seems to have been disabled/removed in VS2012.

在该ASP.NET/WCF web工程调试,无论是测试 - >运行和性能测试(由pressing F5或通过连接过程的启动)>调试子菜单被禁用。在VS2010虽然测试 - >运行的子菜单仍然只启用了测试 - >调试子菜单被禁用。我们用这种方式来轻松地在Web项目中调试服务。没有办法让该行为背面或解决方法吗?

When the ASP.NET/WCF web project is debugged (launched by pressing F5 or via attach process), both the TEST->Run and TEST->Debug sub-menus are disabled. In VS2010 only Test->Debug sub-menus were disabled while Test->Run sub-menus were still enabled. We use this way to easily debug the services within the web project. Any way to get that behavior back or workaround?

调试运行期间对ASP.NET开发服务器似乎并不被适用于VS2012或至少我无法得到它的工作。

Debugging While Running on ASP.NET Development Server doesn't seem to be applicable to VS2012 or at least I can't get it to work.

推荐答案

我最后写一个快速插件。事实证明,像VS2012,VS2012测试运行也可以运行测试的Web项目正在调试的时候。它就是这么菜单选项被禁用。

I ended up writing a quick addon. It turns out that like VS2012, VS2012 test runner can also run the tests when the web project is being debugged. It is just that menu options are disabled.

这篇关于如何运行在Web项目正在调试的同时测试?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆