Skip to content
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

NuGet for test projects #885

Open
vslee opened this issue Aug 1, 2021 · 3 comments
Open

NuGet for test projects #885

vslee opened this issue Aug 1, 2021 · 3 comments

Comments

@vslee
Copy link

vslee commented Aug 1, 2021

Is your feature request related to a problem? Please describe.

The test projects contain useful things for consumers, such as JoinableTaskTestBase.SimulateUIThread().

Describe the solution you'd like

NuGets which contain the test projects. For example:
https://www.nuget.org/packages/Microsoft.EntityFrameworkCore.Relational.Specification.Tests/
https://www.nuget.org/packages/Microsoft.Extensions.DependencyInjection.Specification.Tests/
https://www.nuget.org/packages/Microsoft.AspNetCore.Identity.Specification.Tests/

Describe alternatives you've considered

Currently, I fetch the vs-threading source every once in a while and add a project reference in Visual Studio. But a NuGet would be a cleaner solution.

@AArnott
Copy link
Member

AArnott commented Aug 17, 2021

You don't actually want the unit test themselves, but rather you're looking for us to share the helper methods we use within the tests so that you can use them in your tests as well, I believe.

That's a fine idea. You mention SimulateUIThread as one example. Are there others?

@vslee
Copy link
Author

vslee commented Aug 17, 2021

I am only a light user, so SimulateUIThread is the only one I know of. However, if you only include a few select helper methods in the NuGet, then ppl who are looking for others may get confused as to why it's not working. You're right that the unit tests themselves are not needed in the NuGet, but since they will only be referenced by other test projects, a little bit of bloat wouldn't hurt. Thus, it may be easier to just include everything.

@AArnott
Copy link
Member

AArnott commented Aug 17, 2021

We're not going to ship our unit tests themselves in nuget packages. I don't know how offering a new test utility package with some helper methods would confuse people as to why it's not working unless they were previously reaching directly into our test projects, which isn't something we support and I hope is quite rare.

But as it is, this is a low priority relative to our many other deliverables, so I don't think we'll be taking either direction right away.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants