I have VS 2010 Ultimate with ReSharper, Reflector, and SpecFlow extensions. I use SpecFlow in one of my test projects along with WebDriver for automated UI testing. I am now approaching about 400 individual test scenarios in that project.
When I open Visual Stud开发者_如何学Pythonio, everything is fine (aside from some of the usual synchronizing slowness that comes with ReSharper). However as soon as I click the tab to show my built-in "Test View", VS freezes up for about 60 seconds while the tests load.
I'm concerned this is going to get worse as we put more tests into the SpecFlow project. Is there anything I can change in my TestSettings file to make this go faster? Should I try and ditch the TestSettings file altogether, or is this not even possible? Or, should I switch from using MSTest with SpecFlow to something else like NUnit, to make the Test View slowness go away?
Took me all damn night but I figured it out. I had the following projects & namespaces:
MyCompany.MyApp (proj dll)
MyCompany.MyApp (proj namespace)
MyCompany.MyApp.UnitTest (proj dll)
MyCompany.MyApp (proj namespace)
MyCompany.MyApp.WebTest (proj dll)
MyCompany.MyApp (proj namespace)
The specflow / webdriver project was the "WebTest" project. By changing the project's default namespace from "MyCompany.MyApp" to "MyCompany.MyApp.WebTest", and updating the namespaces of all files to match this, the test view now loads in 3 seconds.
Hope this helps someone. The Test View must have been trying to solve some kind of namespace conflict between the test project and the app project.
精彩评论