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

Update to .NET 9 GA. Update some test dependencies. #2990

Merged
merged 12 commits into from
Nov 14, 2024
17 changes: 4 additions & 13 deletions .github/workflows/dotnetcore.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ on:
- dev

env:
TargetNet9: True
pmaytak marked this conversation as resolved.
Show resolved Hide resolved
TargetNet8: True
TargetNetNext: True

jobs:
build:
Expand All @@ -29,19 +28,11 @@ jobs:
steps:
- name: Checkout repository
uses: actions/[email protected]

- name: Setup .NET 6.0.x
msbw2 marked this conversation as resolved.
Show resolved Hide resolved
uses: actions/[email protected]
with:
dotnet-version: 6.0.x
- name: Setup .NET 8.0.x
uses: actions/[email protected]
with:
dotnet-version: 8.0.x
- name: Setup .NET 9.0.x

- name: Setup .NET 9.x
uses: actions/[email protected]
with:
dotnet-version: 9.0.100-rc.2.24474.11
dotnet-version: 9.x
pmaytak marked this conversation as resolved.
Show resolved Hide resolved

- name: Run the tests
run: dotnet test Wilson.sln --collect:"XPlat Code Coverage" --settings:./build/CodeCoverage.runsettings
pmaytak marked this conversation as resolved.
Show resolved Hide resolved
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
<AssemblyName>Microsoft.IdentityModel.Benchmarks</AssemblyName>
<PackageId>Microsoft.IdentityModel.Benchmarks</PackageId>
<OutputType>Exe</OutputType>
<TargetFrameworks>net6.0;net8.0</TargetFrameworks>
pmaytak marked this conversation as resolved.
Show resolved Hide resolved
<TargetFrameworks Condition="'$(TargetNet9)'== 'True'">$(TargetFrameworks); net9.0</TargetFrameworks>
<TargetFrameworks>net6.0;net8.0;net9.0</TargetFrameworks>
<TargetFrameworks Condition="'$(TargetNetNext)'== 'True'">$(TargetFrameworks); </TargetFrameworks>
<SignAssembly>True</SignAssembly>
<DelaySign>True</DelaySign>
<AssemblyOriginatorKeyFile>$(MSBuildThisFileDirectory)..\..\build\35MSSharedLib1024.snk</AssemblyOriginatorKeyFile>
Expand Down
2 changes: 1 addition & 1 deletion build/common.props
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@

<ItemGroup>
<!-- Protects against sync-over-async: https://github.com/microsoft/vs-threading/blob/main/doc/analyzers/index.md. -->
<PackageReference Include="Microsoft.VisualStudio.Threading.Analyzers" Version="17.9.28" PrivateAssets="all" />
<PackageReference Include="Microsoft.VisualStudio.Threading.Analyzers" Version="17.11.20" PrivateAssets="all" />
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="$(MicrosoftSourceLinkGitHubVersion)" PrivateAssets="All"/>
</ItemGroup>

Expand Down
8 changes: 4 additions & 4 deletions build/dependenciesTest.props
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@
<BannedApiAnalyzersVersion>3.3.4</BannedApiAnalyzersVersion>
<DotNetCoreAppRuntimeVersion>2.1.30</DotNetCoreAppRuntimeVersion>
<MicrosoftAzureKeyVaultCryptographyVersion>3.0.5</MicrosoftAzureKeyVaultCryptographyVersion>
<MicrosoftNETTestSdkVersion>17.11.0</MicrosoftNETTestSdkVersion>
<MicrosoftNETTestSdkVersion>17.11.1</MicrosoftNETTestSdkVersion>
<NetStandardVersion>2.0.3</NetStandardVersion>
<NewtonsoftVersion>13.0.3</NewtonsoftVersion>
<SystemNetHttp>4.3.4</SystemNetHttp>
<SystemSecurityClaimsVersion>4.3.0</SystemSecurityClaimsVersion>
<SystemTextJson>8.0.5</SystemTextJson>
<SystemTextRegularExpressions>4.3.1</SystemTextRegularExpressions>
<XunitRunnerConsoleVersion>2.9.0</XunitRunnerConsoleVersion>
<XunitRunnerConsoleVersion>2.9.2</XunitRunnerConsoleVersion>
<XunitRunnerVisualStudioVersion>2.8.2</XunitRunnerVisualStudioVersion>
<XunitVersion>2.9.0</XunitVersion>
<XunitVersion>2.9.2</XunitVersion>
<MicrosoftRestClientRuntimeVersion>2.3.24</MicrosoftRestClientRuntimeVersion>
</PropertyGroup>
<PropertyGroup Condition="$([MSBuild]::IsTargetFrameworkCompatible('$(TargetFramework)', 'net9.0'))">
<XunitRunnerVisualStudioVersion>3.0.0-pre.35</XunitRunnerVisualStudioVersion>
<XunitRunnerVisualStudioVersion>3.0.0-pre.49</XunitRunnerVisualStudioVersion>
</PropertyGroup>
</Project>
6 changes: 3 additions & 3 deletions build/targets.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<SrcTargets Condition="'$(LocalBuild)' != 'True'">net462;net472;netstandard2.0;net6.0;net8.0</SrcTargets>
<SrcTargets Condition="'$(LocalBuild)' == 'True'">netstandard2.0;net8.0</SrcTargets>
<SrcTargets Condition="'$(TargetNet9)' == 'True'">$(SrcTargets);net9.0</SrcTargets>
pmaytak marked this conversation as resolved.
Show resolved Hide resolved
<SrcTargets Condition="'$(LocalBuild)' != 'True'">net462; net472; netstandard2.0; net6.0; net8.0; net9.0</SrcTargets>
<SrcTargets Condition="'$(LocalBuild)' == 'True'">netstandard2.0; net8.0; net9.0</SrcTargets>
<SrcTargets Condition="'$(TargetNetNext)'== 'True'">$(SrcTargets); </SrcTargets>
</PropertyGroup>
</Project>
8 changes: 4 additions & 4 deletions build/targetsTest.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<PropertyGroup>
<TestTargets Condition="'$(LocalBuild)' != 'True'">net462;net472;net6.0;net8.0</TestTargets>
<TestTargets Condition="'$(LocalBuild)' == 'True'">net8.0</TestTargets>
<TestTargets Condition="'$(TargetNet9)' == 'True'">$(TestTargets);net9.0</TestTargets>
</PropertyGroup>
<TestTargets Condition="'$(LocalBuild)' != 'True'">net462; net472; net6.0; net8.0; net9.0</TestTargets>
<TestTargets Condition="'$(LocalBuild)' == 'True'">net8.0; net9.0</TestTargets>
<TestTargets Condition="'$(TargetNetNext)'== 'True'">$(TestTargets); </TestTargets>
</PropertyGroup>
</Project>
23 changes: 2 additions & 21 deletions build/template-Build-run-tests-sign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,30 +7,11 @@ steps:
- script: echo $(MicrosoftIdentityModelVersion)
displayName: 'display MicrosoftIdentityModelVersion'

- task: UseDotNet@2
displayName: 'Use .NET Core sdk 2.x'
inputs:
version: 2.x
installationPath: $(Agent.ToolsDirectory)/dotnet

- task: UseDotNet@2
displayName: 'Use .NET Core sdk 6.x'
inputs:
version: 6.x
installationPath: $(Agent.ToolsDirectory)/dotnet

- task: UseDotNet@2
displayName: 'Use .NET Core sdk 8.x'
inputs:
version: 8.x
installationPath: $(Agent.ToolsDirectory)/dotnet

- task: UseDotNet@2
displayName: 'Use .Net Core SDK 9.x'
inputs:
version: 9.0.100-rc.2.24474.11
includePreviewVersions: true
condition: eq(variables['TargetNet9'], 'True')
version: 9.x
installationPath: $(Agent.ToolsDirectory)/dotnet

- task: DotNetCoreCLI@2
displayName: 'dotnet --list-sdks'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFrameworks Condition="'$(TargetNet9)' == 'True'">$(TargetFramework); net9.0</TargetFrameworks>
<TargetFrameworks>net8.0; net9.0</TargetFrameworks>
<TargetFrameworks Condition="'$(TargetNetNext)'== 'True'">$(TargetFrameworks); </TargetFrameworks>
<OutputType>Exe</OutputType>
<PublishTrimmed>true</PublishTrimmed>
<TrimMode>full</TrimMode>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

<PropertyGroup>
<!-- This test only needs to run on .NET -->
<TargetFrameworks>net8.0</TargetFrameworks>
<TargetFrameworks Condition="'$(TargetNet9)'== 'True'">$(TargetFrameworks);net9.0</TargetFrameworks>
<TargetFrameworks>net8.0; net9.0</TargetFrameworks>
<TargetFrameworks Condition="'$(TargetNetNext)'== 'True'">$(TargetFrameworks); </TargetFrameworks>
<langversion>12</langversion>
<Version>1.0.0-preview</Version>
</PropertyGroup>
Expand Down
Loading