阻止Visual Studio 2010启动ASP.net开发服务器

时间:2022-12-30 02:01:52

I have 3 projects in my solution.

我的解决方案中有3个项目。

Whenever I attempt to debug a unit test in any of the projects, VS2010 starts 3 (1 for each project) ASP.net development servers.

每当我尝试在任何项目中调试单元测试时,VS2010启动3(每个项目1个)ASP.net开发服务器。

The issue I have is that VS2010 takes a long time starting these development servers and as a result I spend a lot of time waiting whilst I attempt to debug unit tests.

我遇到的问题是VS2010需要很长时间才能启动这些开发服务器,因此我在尝试调试单元测试时花了很多时间等待。

I am not sure why VS2010 does this... Is there a valid reason? Is there a way to prevent these development servers from starting when debugging unit tests?

我不确定为什么VS2010这样做......有正当理由吗?有没有办法阻止这些开发服务器在调试单元测试时启动?

1 个解决方案

#1


20  

Not sure why it does this by default, but if your question is really "how do I turn this off", then do this:

不确定为什么默认情况下会这样做,但如果您的问题确实是“如何关闭”,请执行以下操作:

  1. Select the ASP.NET project in your solution
  2. 在解决方案中选择ASP.NET项目
  3. Press F4 to bring up the properties (not the properties tab you get when choosing Properties from the context menu)
  4. 按F4调出属性(不是从上下文菜单中选择“属性”时获得的属性选项卡)
  5. Change Development Server -> Always Start When Debugging to "False"
  6. 更改开发服务器 - >调试时总是启动“False”

#1


20  

Not sure why it does this by default, but if your question is really "how do I turn this off", then do this:

不确定为什么默认情况下会这样做,但如果您的问题确实是“如何关闭”,请执行以下操作:

  1. Select the ASP.NET project in your solution
  2. 在解决方案中选择ASP.NET项目
  3. Press F4 to bring up the properties (not the properties tab you get when choosing Properties from the context menu)
  4. 按F4调出属性(不是从上下文菜单中选择“属性”时获得的属性选项卡)
  5. Change Development Server -> Always Start When Debugging to "False"
  6. 更改开发服务器 - >调试时总是启动“False”