Skip to content

Commit

Permalink
.NET 8 update (#48)
Browse files Browse the repository at this point in the history
* Replace .NET 6 with .NET 8 and update ref assemblies to final version

* Update .NET 6 ref version

* Update .NET 7 ref version

* Update .NET 4.x ref versions

* Add combined assembly to unit tests

* Add README to NuGet package, with minor improvements

* Reformat README for better display on NuGet.org
  • Loading branch information
reflectronic authored Mar 1, 2024
1 parent d2ac71f commit e4ba155
Show file tree
Hide file tree
Showing 27 changed files with 3,001 additions and 2,912 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies.net461" Version="1.0.2" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies.net461" Version="1.0.3" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
366 changes: 183 additions & 183 deletions Basic.Reference.Assemblies.Net461/Generated.targets

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies.net472" Version="1.0.0" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies.net472" Version="1.0.3" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
468 changes: 234 additions & 234 deletions Basic.Reference.Assemblies.Net472/Generated.targets

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="6.0.9" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="6.0.27" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
318 changes: 159 additions & 159 deletions Basic.Reference.Assemblies.Net60/Generated.cs

Large diffs are not rendered by default.

318 changes: 159 additions & 159 deletions Basic.Reference.Assemblies.Net60/Generated.targets

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.WindowsDesktop.App.Ref" Version="6.0.9" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
<PackageReference Include="Microsoft.WindowsDesktop.App.Ref" Version="6.0.27" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
94 changes: 47 additions & 47 deletions Basic.Reference.Assemblies.Net60Windows/Generated.cs

Large diffs are not rendered by default.

94 changes: 47 additions & 47 deletions Basic.Reference.Assemblies.Net60Windows/Generated.targets

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="7.0.0-rc.1.22426.10" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="7.0.16" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
326 changes: 163 additions & 163 deletions Basic.Reference.Assemblies.Net70/Generated.cs

Large diffs are not rendered by default.

326 changes: 163 additions & 163 deletions Basic.Reference.Assemblies.Net70/Generated.targets

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="8.0.0-preview.7.23375.6" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" ExcludeAssets="analyzers" />
<PackageReference Include="Microsoft.NETCore.App.Ref" Version="8.0.2" IncludeAssets="none" PrivateAssets="all" GeneratePathProperty="true" ExcludeAssets="analyzers" />
</ItemGroup>

<Import Project="Generated.targets" />
Expand Down
326 changes: 163 additions & 163 deletions Basic.Reference.Assemblies.Net80/Generated.cs

Large diffs are not rendered by default.

326 changes: 163 additions & 163 deletions Basic.Reference.Assemblies.Net80/Generated.targets

Large diffs are not rendered by default.

18 changes: 15 additions & 3 deletions Basic.Reference.Assemblies.UnitTests/TestData.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
using System;
extern alias Combined;

using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

using CombinedAssembly = Combined::Basic.Reference.Assemblies;

namespace Basic.Reference.Assemblies.UnitTests
{
Expand All @@ -21,6 +22,9 @@ public static IEnumerable<object[]> ApplicationReferences
new object[] { "net6.0", Net60.References.All },
new object[] { "net7.0", Net70.References.All },
new object[] { "net8.0", Net70.References.All },

new object[] { "netstandard2.0", CombinedAssembly.NetStandard20.References.All },
new object[] { "net8.0", CombinedAssembly.Net80.References.All },
};
}
}
Expand All @@ -33,6 +37,8 @@ public static IEnumerable<object[]> LibraryReferences
{
new object[] { "netstandard1.3", NetStandard13.References.All },
new object[] { "netstandard2.0", NetStandard20.References.All },

new object[] { "netstandard2.0", CombinedAssembly.NetStandard20.References.All },
};
}
}
Expand All @@ -57,6 +63,12 @@ public static IEnumerable<object[]> AllValues
new object[] { "net6.0", Net60.ReferenceInfos.AllValues },
new object[] { "net7.0", Net70.ReferenceInfos.AllValues },
new object[] { "net8.0", Net80.ReferenceInfos.AllValues },
new object[] { "net8.0", Net80.ReferenceInfos.AllValues },
new object[] { "net8.0", Net80.ReferenceInfos.AllValues },

new object[] { "netstandard2.0", CombinedAssembly.NetStandard20.ReferenceInfos.AllValues },
new object[] { "net472", CombinedAssembly.Net472.ReferenceInfos.AllValues },
new object[] { "net8.0", CombinedAssembly.Net80.ReferenceInfos.AllValues },
};
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<DefineConstants>$(DefineConstants);BASIC_REFERENCE_ASSEMBLIES_COMBINED</DefineConstants>
</PropertyGroup>

<Import Project="Generated.Net60.targets" />
<Import Project="Generated.Net80.targets" />
<Import Project="Generated.NetStandard20.targets" />
<Import Project="Generated.Net472.targets" />
</Project>
8 changes: 3 additions & 5 deletions Basic.Reference.Assemblies/BasicReferenceAssemblies.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,18 @@
using Microsoft.CodeAnalysis;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Basic.Reference.Assemblies
{
public static class ReferenceAssemblies
{
public static IEnumerable<PortableExecutableReference> Net60 => Basic.Reference.Assemblies.Net60.References.All;
public static IEnumerable<PortableExecutableReference> Net80 => Basic.Reference.Assemblies.Net80.References.All;
public static IEnumerable<PortableExecutableReference> NetStandard20 => Basic.Reference.Assemblies.NetStandard20.References.All;
public static IEnumerable<PortableExecutableReference> Net472 => Basic.Reference.Assemblies.Net472.References.All;

public static IEnumerable<PortableExecutableReference> Get(ReferenceAssemblyKind kind) => kind switch
{
ReferenceAssemblyKind.Net60 => Net60,
ReferenceAssemblyKind.Net80 => Net80,
ReferenceAssemblyKind.NetStandard20 => NetStandard20,
ReferenceAssemblyKind.Net472 => Net472,
_ => throw new Exception($"Invalid kind: {kind}")
Expand All @@ -23,7 +21,7 @@ public static class ReferenceAssemblies

public enum ReferenceAssemblyKind
{
Net60,
Net80,
NetStandard20,
Net472,
}
Expand Down
Loading

0 comments on commit e4ba155

Please sign in to comment.