Skip to content

Commit 2f8a80e

Browse files
committed
test: Update LangVersion for UnitTests.NetStandard.csproj to match elsewhere
1 parent 9fa85ad commit 2f8a80e

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

sdk/test/NetStandard/UnitTests/UnitTests.NetStandard.csproj

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,20 @@
1818
<GenerateAssemblyDescriptionAttribute>false</GenerateAssemblyDescriptionAttribute>
1919

2020
<NoWarn>CS1591,CS0612,CS0618,xUnit1013,NU1701</NoWarn>
21-
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
22-
<SignAssembly>true</SignAssembly>
23-
<LangVersion Condition="'$(TargetFramework)' == 'netstandard2.0'">8.0</LangVersion>
21+
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
22+
<SignAssembly>true</SignAssembly>
2423
</PropertyGroup>
24+
<!--
25+
For .NET 8 LangVersion is set to 11 to allow using static interface methods. This is to allow
26+
the service interface factory method to exist for AWSSDK.Extensions.NETCore.Setup.
27+
-->
28+
<PropertyGroup Condition="'$(TargetFramework)' == 'net8.0'">
29+
<LangVersion>11.0</LangVersion>
30+
</PropertyGroup>
31+
<PropertyGroup Condition="'$(TargetFramework)' != 'net8.0'">
32+
<LangVersion>9.0</LangVersion>
33+
</PropertyGroup>
34+
2535
<Choose>
2636
<When Condition=" '$(AWSKeyFile)' == '' ">
2737
<PropertyGroup>

0 commit comments

Comments
 (0)