-
Notifications
You must be signed in to change notification settings - Fork 754
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Latest Specflow caused "Stopped Working" dialog popup .Net Core 2.2 #1446
Comments
If you set this to false, you shouldn't get the error message. |
possible a duplicate of #1445 |
Thanks for the quick reply :) |
@jronay when do you get the error then? |
If I load the project and click on the Calculator.feature file then the stopped working popup occurs. The calculator feature uses the basic calculator add tests. |
p.s. I'm not sure I follow your comment about not having a dependency on the test SDK, because for those of us that use NUnit, the specflow tests will not run without it -- seems to me if you support NUnit, then there is a "dependency" on the test SDK, intended or not. |
The Test SDK dependency story is "complicated". It is needed for the unit test project that VSTest finds tests. No test runner needs the dependency. It's only needed because of the tooling. And I think it's only needed for .NET Core. Not for .NET Desktop Framework. Additionally the different test frameworks have different approaches to it: SpecFlow+Runner: the SpecRun.Runner package has the dependency (https://www.nuget.org/packages/SpecRun.Runner/3.0.246-beta) As SpecFlow sits on top of the test frameworks/Runner, I don't think it is it's job to make sure, that you can also execute the tests. We also don't have dependencies on the various adapter/runner packages from xUnit/MSTest/NUnit. I understand that it makes it easier for the user, but it is one more dependency, we have to care about. Perhaps we will change this sometime in the future. Depends how much issues we get about it. But currently I want to hold the dependencies as low as possible. You would also need to add this dependency yourself, if you use NUnit without SpecFlow. |
@SabotageAndi I understand part of your reasoning. But just to be clear, in .Net Core 2.2, specflow with NUnit does not work at all (you can't run the tests because they are not detected) unless you install the test SDK mentioned. |
Some provoking questions, (only for thought process, please take no offense in them): Can you run your NUnit Tests without NUnit3TestAdapter in VS? - No I have the view, it is the same with Microsoft.NET.Test.Sdk. Needing this dependency is sadly and the user has to know it. The expectation from Microsoft is, that you start with one of their unit test projects. These contain the reference to the test sdk. Have a look at the documentation:
You see in both pages, the Microsoft.NET.Test.Sdk is referenced. |
Closed because of inactivity |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
SpecFlow Version:
Used Test Runner
Version number: NUnt3TestAdapter 3.13.0
Visual Studio Version
Are the latest Visual Studio updates installed?
.NET Framework:
Test Execution Method:
<SpecFlow> Section in app.config
Repro Project
Issue Description
This dialog box pops up frequently"
"TechTalk.SpecFlow.VisualStudioCodeBehind has stopped working"
Steps to Reproduce
This dialog is still popping up with all the recommended configurations in place.
I believe this is a bug as it has been present for the last 3 versions of Visual Studio.
Running Visual Studio Enterprise 2017 v15.9.8
Installed dependencies:
Project configuration:
specflow.json contents:
Note: The tests would not run / be detected unless the Microsoft.NET.Test.Sdk was installed as shown above. The error without the sdk installed indicated “Unable to run NUnit unit test. Unable to find testhost.dll Please publish your test project and retry”
See the referenced post here: microsoft/vstest#1870
I would like to know if others to see the “Stopped Working“ dialogue mentioned here and if there is any recommended workaround to prevent this.
The text was updated successfully, but these errors were encountered: