-
Notifications
You must be signed in to change notification settings - Fork 325
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
Do we need Microsoft.NET.Test.Sdk package to run tests? #986
Comments
From @sharwell on August 3, 2017 20:41 I'm not sure I understand the question. The main items added by Microsoft.NET.Test.Sdk are the UnitTestContainer capability and setting the IsTestProject property. The former is supposed to be the trigger for tests, but several older test adapter implementations do not add it. Roslyn does add it, so the Microsoft.NET.Test.Sdk package should not be needed for an IDE to know which projects are test projects and which ones are not. |
From @Pilchie on August 7, 2017 22:8 @ManishJayaswal or @srivatsn - do you know the right home for this? |
Yes the test SDK does a few things like generate a Main method to keep the compiler happy and sets a few other things. There was an investigation about what we can do to either remove the requirement or make the Test.Sdk a real MSBuild SDK instead of a package. Moving to Microsoft/vstest |
@alrz You can take individual nuget reference of |
so, shouldn't we add it to Roslyn? if not how can I workaround this for now (besides referencing it from all test projects)? |
@alrz It's still not clear to me what the benefit would be if we add it to Roslyn. Can you describe a developer scenario which currently fails but would work if we referenced that package? |
I get this in Rider. This was not shown in the past. I didn't check yet if this is required in older commits. |
@alrz Ah. This was caused by dotnet/roslyn#20569. The solution is dotnet/roslyn#21017, but it's blocked due to some performance concerns that need to be thoroughly tested to make sure we don't break developers working on Roslyn. |
I merged dotnet/roslyn#21017 locally but the issue remains -- Rider, R# and VS "Run Tests" are unable to discover any tests. I have no idea whether this belongs to either of IDEs or some test config/dependency. |
@alrz After merging it, you'll need to re-run the restore script and then rebuild the entire solution. After that things should be working again. |
@alrz : Did you get your answer? Can i close this issue? |
I no longer use IDE to run tests so this discussion is moot. Feel free to close the issue. |
Microsoft.Test.Sdk feels like injecting a Main method for some reason. I tried to read up why it does so or why this package is even needed: microsoft/vstest#986 has something to do with magically supporting netcoreapp 1.1 targets but i dread reading more. This is the sort of thing that tires me so much doing .NET development.. The whole point this dependency is even needed infuriates me.
Microsoft.Test.Sdk feels like injecting a Main method for some reason. I tried to read up why it does so or why this package is even needed: microsoft/vstest#986 has something to do with magically supporting netcoreapp 1.1 targets but i dread reading more. This is the sort of thing that tires me so much doing .NET development.. The whole point this dependency is even needed infuriates me.
Microsoft.Test.Sdk feels like injecting a Main method for some reason. I tried to read up why it does so or why this package is even needed: microsoft/vstest#986 has something to do with magically supporting netcoreapp 1.1 targets but i dread reading more. This is the sort of thing that tires me so much doing .NET development.. The whole point this dependency is even needed infuriates me.
Microsoft.Test.Sdk feels like injecting a Main method for some reason. I tried to read up why it does so or why this package is even needed: microsoft/vstest#986 has something to do with magically supporting netcoreapp 1.1 targets but i dread reading more. This is the sort of thing that tires me so much doing .NET development.. The whole point this dependency is even needed infuriates me.
Microsoft.Test.Sdk feels like injecting a Main method for some reason. I tried to read up why it does so or why this package is even needed: microsoft/vstest#986 has something to do with magically supporting netcoreapp 1.1 targets but i dread reading more. This is the sort of thing that tires me so much doing .NET development.. The whole point this dependency is even needed infuriates me.
From @alrz on August 3, 2017 20:27
This is requested by Rider, I wonder if that is not the case for VS/RS.
Copied from original issue: dotnet/roslyn#21313
The text was updated successfully, but these errors were encountered: