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

Add .NET 9 in tests projects #2313

Merged
merged 32 commits into from
Nov 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
1b35e31
Add .NET 9 in tests for AspNetCore, Runtime and Process instrumentati…
xiang17 Nov 11, 2024
02007bb
Update CI to install .NET 9
xiang17 Nov 11, 2024
1c3ced6
Build projects with .NET 9 SDK
xiang17 Nov 12, 2024
927b18a
The last CI run failed with `Unable to find package Microsoft.AspNetC…
xiang17 Nov 12, 2024
ca18ad3
ubuntu-latest is pointing to a newer version than ubuntu-24.04 now. b…
xiang17 Nov 12, 2024
ba5056f
Upgrade Kafka and StackExchangeRedis integration tests which uses .NE…
xiang17 Nov 12, 2024
5d7f503
Update .NET SDK version for AOT Compatibility Test
xiang17 Nov 12, 2024
e034be3
Install .NET 9 for AOT tests. The .NET SDK 9 is not installed by defa…
xiang17 Nov 12, 2024
30341a1
Update docker invokation in CI to have both .NET 8 and 9
xiang17 Nov 12, 2024
c723ee1
In docker-compose.net8.0.yml, setting BUILD_SDK_VERSION to 9.0 would …
xiang17 Nov 12, 2024
cf4cef8
The tests are failing after upgrading to .NET 9. Disabling them for n…
xiang17 Nov 12, 2024
c875d77
remove unused using statement
xiang17 Nov 12, 2024
3c7638e
Removing .net 9 docker tests because the kafka and StackExchangeRedis…
xiang17 Nov 12, 2024
de143fa
Amend last commit: update CI to not invoke .NET 9 for docker integ tests
xiang17 Nov 12, 2024
0f36251
Add .NET 9 in target framework for AOT compatibility test
xiang17 Nov 12, 2024
0d5bcda
Merge branch 'main' into xiang17/dotnet9Tests
xiang17 Nov 13, 2024
0e6cf78
Merge branch 'xiang17/dotnet9CIExperiment' into xiang17/dotnet9Tests
xiang17 Nov 13, 2024
e998612
Rename tag to `SupportedNetTargetsWithNet9` and add `net9.0` target t…
xiang17 Nov 13, 2024
99585b3
update global.json because dotnet docker image is updated with .NET 9…
xiang17 Nov 13, 2024
a702848
Add `net9.0` for AspNetCore test. This needs to be individually confi…
xiang17 Nov 13, 2024
10d5f58
Merge branch 'main' into xiang17/dotnet9Tests
xiang17 Nov 13, 2024
64e2ed1
remove unused TargetFrameworksForAotCompatibilityTests
xiang17 Nov 13, 2024
fa1a853
attempt to add `net9.0` to all libraries and test projects
xiang17 Nov 13, 2024
f0d8c21
Fix past commit errors: Make TargetFramework to plural
xiang17 Nov 14, 2024
ecef58a
Fix past commit errors: update to match any target framework
xiang17 Nov 14, 2024
be2d97d
Reverting the past 3 commits with git revert --no-commit HEAD~3..HEAD
xiang17 Nov 14, 2024
47f3591
Add `net9.0` to SupportedNetTargets to apply to all
xiang17 Nov 14, 2024
6e01df5
Don't use .NET 9 for two failing projects
xiang17 Nov 14, 2024
dc938d9
Fix past commit errors: rename SupportedNetTargetsWithNet9 to Support…
xiang17 Nov 14, 2024
2906048
Update versions to latest stable in test package
xiang17 Nov 14, 2024
36cd65c
Merge branch 'main' into xiang17/dotnet9Tests
Kielek Nov 14, 2024
34e9974
add net9 for eventcounter tests
Kielek Nov 14, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/Component.BuildTest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ on:
required: false
type: string
tfm-list:
default: '[ "net462", "net8.0" ]'
default: '[ "net462", "net8.0", "net9.0" ]'
xiang17 marked this conversation as resolved.
Show resolved Hide resolved
required: false
type: string
test-case-filter:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ jobs:
with:
project-name: OpenTelemetry.Instrumentation.AspNetCore
code-cov-name: Instrumentation.AspNetCore
tfm-list: '[ "net8.0" ]'
tfm-list: '[ "net8.0", "net9.0" ]'

build-test-instrumentation-aws:
needs: detect-changes
Expand Down Expand Up @@ -279,7 +279,7 @@ jobs:
with:
project-name: OpenTelemetry.Instrumentation.EventCounters
code-cov-name: Instrumentation.EventCounters
tfm-list: '[ "net8.0" ]'
tfm-list: '[ "net8.0", "net9.0" ]'

build-test-instrumentation-grpccore:
needs: detect-changes
Expand Down
5 changes: 3 additions & 2 deletions build/Common.nonprod.props
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@
<MicrosoftExtensionsHostingPkgVer>8.0.1</MicrosoftExtensionsHostingPkgVer>
<MicrosoftNETTestSdkPkgVer>[17.11.1,18.0)</MicrosoftNETTestSdkPkgVer>
<OpenTelemetryExporterInMemoryPkgVer>$(OpenTelemetryCoreLatestVersion)</OpenTelemetryExporterInMemoryPkgVer>
<SupportedNetTargets>net8.0</SupportedNetTargets>
<TargetFrameworksForAotCompatibilityTests>net9.0;net8.0</TargetFrameworksForAotCompatibilityTests>
<!-- OmniSharp/VS Code requires TargetFrameworks to be in descending order for IntelliSense and analysis. -->
<SupportedNetTargets>net9.0;net8.0</SupportedNetTargets>
<SupportedNetTargetsWithoutNet9>net8.0</SupportedNetTargetsWithoutNet9>
<XUnitRunnerVisualStudioPkgVer>[2.8.2,3.0)</XUnitRunnerVisualStudioPkgVer>
<XUnitPkgVer>[2.9.0,3.0)</XUnitPkgVer>
<WiremockNetPkgVer>[1.6.3,2.0)</WiremockNetPkgVer>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFrameworks>$(TargetFrameworksForAotCompatibilityTests)</TargetFrameworks>
xiang17 marked this conversation as resolved.
Show resolved Hide resolved
<TargetFrameworks>$(SupportedNetTargets)</TargetFrameworks>
<PublishAot>true</PublishAot>
<TrimmerSingleWarn>false</TrimmerSingleWarn>
<EventSourceSupport>true</EventSourceSupport>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
<Import Project="$(RepoRoot)\src\OpenTelemetry.Exporter.Geneva\Common.GenevaExporter.props"/>

<PropertyGroup>
<!-- OmniSharp/VS Code requires TargetFrameworks to be in descending order for IntelliSense and analysis. -->
<TargetFrameworks>$(SupportedNetTargets)</TargetFrameworks>
<TargetFrameworks Condition="$(OS) == 'Windows_NT'">$(TargetFrameworks);net48;net472;net471;net47;net462</TargetFrameworks>
<OutputType>Exe</OutputType>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<!-- OmniSharp/VS Code requires TargetFrameworks to be in descending order for IntelliSense and analysis. -->
<TargetFrameworks>$(SupportedNetTargets)</TargetFrameworks>
<TargetFrameworks Condition="$(OS) == 'Windows_NT'">$(TargetFrameworks);net48;net472;net471;net47;net462</TargetFrameworks>
<OutputType>Exe</OutputType>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
<Import Project="$(RepoRoot)\src\OpenTelemetry.Exporter.Geneva\Common.GenevaExporter.props" />

<PropertyGroup>
<!-- OmniSharp/VS Code requires TargetFrameworks to be in descending order for IntelliSense and analysis. -->
<TargetFrameworks>$(SupportedNetTargets)</TargetFrameworks>
<TargetFrameworks Condition="$(OS) == 'Windows_NT'">$(TargetFrameworks);net48;net472;net471;net47;net462</TargetFrameworks>
<Description>Unit test project for Geneva Exporters for OpenTelemetry.</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<!-- OmniSharp/VS Code requires TargetFrameworks to be in descending order for IntelliSense and analysis. -->
<TargetFrameworks>$(SupportedNetTargets)</TargetFrameworks>
<OutputType>Exe</OutputType>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,13 @@
</PropertyGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net8.0'" >
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="8.0.10" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="8.0.10"/>
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="8.0.11" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="8.0.11"/>
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net9.0'" >
<PackageReference Include="Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation" Version="9.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="9.0.0"/>
</ItemGroup>

<ItemGroup>
Expand Down
Loading
Loading