machine.specifications icon indicating copy to clipboard operation
machine.specifications copied to clipboard

Test Runner with VS2022 Preview dotnet 9

Open mynkow opened this issue 1 year ago • 7 comments

Has anyone a success running tests within VS2022 Preview with dotnet 9?

mynkow avatar Sep 29 '24 19:09 mynkow

Using VS2022, .net 9.0.100

In some projects I get issues as it's using NETStandard.Library 1.6.1 In other projects it uses NETStandard.Library 2.0.1

image and so get error NU1903: Warning As Error: Package 'System.Text.RegularExpressions' 4.3.0 has a known high severity vulnerability,

I wonder if we should target net8?

mikeblakeuk avatar Nov 13 '24 12:11 mikeblakeuk

It works if you add <NuGetAuditMode>direct</NuGetAuditMode>

I use R# Runner.

The only thing is the code looks obsolete (light grey). image

mikeblakeuk avatar Nov 15 '24 15:11 mikeblakeuk

I'll take a look, it's likely we just need to target netstandard2.0

robertcoltheart avatar Nov 15 '24 19:11 robertcoltheart

I'll take a look, it's likely we just need to target netstandard2.0

I had a look and locally this commit seemed sufficient. https://github.com/jnyrup/machine.specifications/commit/8239700b39534351c497e1aa9117383c4e7d5e95 It also tries to account for netstandard2.0 having more capabilities than netstandard1.3. I have no idea if it builds clean with the VS2017 used in the CI for the release/1.0.0 tag.

jnyrup avatar Dec 18 '24 15:12 jnyrup

based on the master branch they target <TargetFrameworks>net472;net6.0</TargetFrameworks> except the Machine.Specifications.Analyzers.csproj

Not sure if that is the issue.

mikeblakeuk avatar Dec 18 '24 15:12 mikeblakeuk

Master branch is in flux at the moment after ignoring it for a long time.

robertcoltheart avatar Dec 18 '24 21:12 robertcoltheart

Ah, so https://github.com/machine/machine.specifications/blob/releases/v1.0.0/src/Machine.Specifications/Machine.Specifications.csproj Has <TargetFrameworks>net35;net40;net45;netstandard1.3</TargetFrameworks>

mikeblakeuk avatar Dec 19 '24 10:12 mikeblakeuk