xunit-dependency-injection icon indicating copy to clipboard operation
xunit-dependency-injection copied to clipboard

Make it work with .NET 6 to .NET 9 and use min versions of dependent packages

Open frogcrush opened this issue 11 months ago • 5 comments

Allows targeting .NET 6 through .NET 9 using the same NuGet package. This is nice for me as some projects are using .NET 8 for LTS and some are on .NET 9.

frogcrush avatar Dec 05 '24 17:12 frogcrush

Allows targeting .NET 6 through .NET 9 using the same NuGet package. This is nice for me as some projects are using .NET 8 for LTS and some are on .NET 9.

Thanks for opening the PR @frogcrush. I think it makes sense. Please give me a couple of days to review, test and merge.

Arash-Sabet avatar Dec 10 '24 02:12 Arash-Sabet

@frogcrush I just had a chance to glance your changes. This is what I am getting:

image

How to resolve such warnings?

Arash-Sabet avatar Dec 10 '24 02:12 Arash-Sabet

Hey, I'm pretty sure that is because to target .NET 6, it uses Microsoft.Extensions.* version 6, .NET 7 uses V7, etc. as say V9 is not tested against .NET 6 and you will get compiler warnings.

If you manage packages for only the test project, you will correctly see that no package updates are available, as NuGet will select the correct version of dependent libraries.

frogcrush avatar Dec 10 '24 14:12 frogcrush

@frogcrush Thanks for your inputs. I'd rather a flawless compile. Can we possibly get rid of .NET 6.0 at all as it's getting closer to its end of lifecycle?

Arash-Sabet avatar Dec 13 '24 12:12 Arash-Sabet

@frogcrush Can you please suggest a plan to test the produced NuGet libraries before deploying to NuGet? How will the end up in NuGet? I have a limited time and I prefer not to enter into any significant challenges in undoing the changes or taking care of broken code in the community.

Arash-Sabet avatar Dec 22 '24 12:12 Arash-Sabet