Skip to content

Commit

Permalink
Remove net7.0 support
Browse files Browse the repository at this point in the history
  • Loading branch information
brminnick committed May 26, 2024
1 parent 06b1901 commit 9ee763a
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 11 deletions.
8 changes: 5 additions & 3 deletions Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<Nullable>enable</Nullable>
<NoWarn>NETSDK1023</NoWarn>
<IsTrimmable>false</IsTrimmable>
<LangVersion>latest</LangVersion>
<ImplicitUsings>enable</ImplicitUsings>
<WarningsAsErrors>nullable</WarningsAsErrors>
<EnforceCodeStyleInBuild>true</EnforceCodeStyleInBuild>
<ProduceReferenceAssembly>true</ProduceReferenceAssembly>
<LatestSupportedNetVersion>net8.0</LatestSupportedNetVersion>
Expand Down Expand Up @@ -34,7 +34,9 @@
CS1711: XML comment has a typeparam tag, but there is no type parameter by that name
CS1712: Type parameter has no matching typeparam tag in the XML comment
CS1723: XML comment has cref attribute that refers to a type parameter
CS1734: XML comment has a paramref tag, but there is no parameter by that name -->
<WarningsAsErrors>nullable,CS0419,CS1570,CS1571,CS1572,CS1573,CS1574,CS1580,CS1581,CS1584,CS1587,CS1589,CS1590,CS1591,CS1592,CS1598,CS1658,CS1710,CS1711,CS1712,CS1723,CS1734</WarningsAsErrors>
CS1734: XML comment has a paramref tag, but there is no parameter by that name
xUnit1012: Null should not be used for type parameter
xUnit2021: Assert.ThrowsAsync is async. The resulting task should be awaited -->
<WarningsAsErrors>nullable,CS0419,CS1570,CS1571,CS1572,CS1573,CS1574,CS1580,CS1581,CS1584,CS1587,CS1589,CS1590,CS1591,CS1592,CS1598,CS1658,CS1710,CS1711,CS1712,CS1723,CS1734,xUnit1012,xUnit2021</WarningsAsErrors>
</PropertyGroup>
</Project>
2 changes: 1 addition & 1 deletion global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "8.0.100",
"version": "8.0.300",
"rollForward": "latestFeature"
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net461;netcoreapp2.1;netcoreapp3.1;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net461;netcoreapp2.1;netcoreapp3.1;net6.0;net8.0</TargetFrameworks>
<ProduceReferenceAssembly>true</ProduceReferenceAssembly>
<LangVersion>latest</LangVersion>
<Nullable>enable</Nullable>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>netstandard2.0;netstandard2.1;netcoreapp3.0;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>netstandard2.0;netstandard2.1;netcoreapp3.0;net6.0;net8.0</TargetFrameworks>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>GitHubApiStatus.Extensions.snk</AssemblyOriginatorKeyFile>
<AssemblyName>GitHubApiStatus.Extensions</AssemblyName>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net46;netcoreapp2.1;netcoreapp3.1;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>net46;netcoreapp2.1;netcoreapp3.1;net6.0;net8.0</TargetFrameworks>
<IsPackable>false</IsPackable>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System;
using System.Net.Http.Headers;
using System.Threading.Tasks;
using System.Net.Http.Headers;
using GitStatus.Shared;
using NUnit.Framework;

Expand Down Expand Up @@ -33,7 +31,11 @@ public void NullNameTest()

//Assert
#pragma warning disable CS8625 // Cannot convert null literal to non-nullable reference type.
#if NET8_0_OR_GREATER
Assert.Throws<ArgumentNullException>(() => gitHubApiStatusService.AddProductHeaderValue(new ProductHeaderValue(null)));
#else
Assert.Throws<ArgumentException>(() => gitHubApiStatusService.AddProductHeaderValue(new ProductHeaderValue(null)));
#endif
#pragma warning restore CS8625 // Cannot convert null literal to non-nullable reference type.
Assert.IsFalse(gitHubApiStatusService.IsProductHeaderValueValid);
}
Expand Down
2 changes: 1 addition & 1 deletion src/GitHubApiStatus/GitHubApiStatus.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>netstandard1.3;netstandard2.0;netstandard2.1;netcoreapp3.0;net6.0;net7.0;net8.0</TargetFrameworks>
<TargetFrameworks>netstandard1.3;netstandard2.0;netstandard2.1;netcoreapp3.0;net6.0;net8.0</TargetFrameworks>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>GitHubApiStatus.snk</AssemblyOriginatorKeyFile>
<AssemblyName>GitHubApiStatus</AssemblyName>
Expand Down

0 comments on commit 9ee763a

Please sign in to comment.