Skip to content

Commit eb8c061

Browse files
committed
(#690) Add support for .NET 8.0 and 9.0
This commit includes bumps to the TargetFrameworks for each project, as well as a change to allow the tests to work when more TargetFrameworks are in play. This obviously didn't happen before, but now that we are testing across more frameworks, the tests are a bit more brittle, so I have changed them to be non parallelizable.
1 parent a33802c commit eb8c061

File tree

10 files changed

+22
-7
lines changed

10 files changed

+22
-7
lines changed

Diff for: .github/workflows/build.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
- name: Fetch all tags and branches
4444
run: git fetch --prune --unshallow
4545

46-
- name: Install .NET SDK 2.1.x, 3.1.x, 5.0.x, 6.0.x, and 7.0.x
46+
- name: Install .NET SDK 2.1.x, 3.1.x, 5.0.x, 6.0.x, 7.0.x, 8.0.x, and 9.0.x
4747
uses: actions/setup-dotnet@v4
4848
with:
4949
dotnet-version: |
@@ -52,6 +52,8 @@ jobs:
5252
5.0.x
5353
6.0.x
5454
7.0.x
55+
8.0.x
56+
9.0.x
5557
5658
- name: Cache Tools
5759
uses: actions/cache@v4

Diff for: src/GitReleaseManager.Cli/GitReleaseManager.Cli.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<PropertyGroup>
33
<OutputType>Exe</OutputType>
44
<AssemblyName>GitReleaseManager</AssemblyName>
5-
<TargetFrameworks>net6.0</TargetFrameworks>
5+
<TargetFrameworks>net6.0;net8.0</TargetFrameworks>
66
<PublishSingleFile>true</PublishSingleFile>
77
<SelfContained>true</SelfContained>
88
<RuntimeIdentifier>win-x64</RuntimeIdentifier>

Diff for: src/GitReleaseManager.Core.Tests/Commands/ExportCommandTests.cs

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public void Setup()
2727
}
2828

2929
[Test]
30+
[NonParallelizable]
3031
public async Task Should_Execute_Command()
3132
{
3233
var options = new ExportSubOptions

Diff for: src/GitReleaseManager.Core.Tests/GitReleaseManager.Core.Tests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
3+
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
44
<Title>GitReleaseManager.Core.Tests</Title>
55
<Description>Test Project for GitReleaseManager.Core</Description>
66
</PropertyGroup>

Diff for: src/GitReleaseManager.Core/GitReleaseManager.Core.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v16.0\TextTemplating\Microsoft.TextTemplating.targets" Condition="Exists('$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v16.0\TextTemplating\Microsoft.TextTemplating.targets')" />
44
<Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v15.0\TextTemplating\Microsoft.TextTemplating.targets" Condition="Exists('$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v15.0\TextTemplating\Microsoft.TextTemplating.targets')" />
55
<PropertyGroup>
6-
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
6+
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
77
<Title>GitReleaseManager.Core</Title>
88
<Description>Create release notes in markdown given a milestone</Description>
99
<IsPackable>false</IsPackable>

Diff for: src/GitReleaseManager.IntegrationTests/GitReleaseManager.IntegrationTests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
3+
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
44
<Title>GitReleaseManager.IntegrationTests</Title>
55
<Description>Integration Test Project for GitReleaseManager</Description>
66
</PropertyGroup>

Diff for: src/GitReleaseManager.Tests/GitReleaseManager.Tests.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<PropertyGroup>
3-
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
3+
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
44
<Title>GitReleaseManager.Tests</Title>
55
<Description>Test Project for GitReleaseManager</Description>
66
</PropertyGroup>

Diff for: src/GitReleaseManager.Tests/ReleaseNotesBuilderTests.cs

+10
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public void NoCommitsNoIssues()
2727
}
2828

2929
[Test]
30+
[NonParallelizable]
3031
public void NoCommitsSomeIssues()
3132
{
3233
AcceptTest(0, CreateIssue(1, "Bug"), CreateIssue(2, "Feature"), CreateIssue(3, "Improvement"));
@@ -55,20 +56,23 @@ public void SingularCommitsNoIssues()
5556
}
5657

5758
[Test]
59+
[NonParallelizable]
5860
public void SingularCommitsSomeIssues()
5961
{
6062
AcceptTest(1, CreateIssue(1, "Bug"), CreateIssue(2, "Feature"), CreateIssue(3, "Improvement"));
6163
Assert.That(true, Is.True); // Just to make sonarlint happy
6264
}
6365

6466
[Test]
67+
[NonParallelizable]
6568
public void SingularCommitsSingularIssues()
6669
{
6770
AcceptTest(1, CreateIssue(1, "Bug"));
6871
Assert.That(true, Is.True); // Just to make sonarlint happy
6972
}
7073

7174
[Test]
75+
[NonParallelizable]
7276
public void NoCommitsSingularIssues()
7377
{
7478
AcceptTest(0, CreateIssue(1, "Bug"));
@@ -83,6 +87,7 @@ public void SomeCommitsSingularIssues()
8387
}
8488

8589
[Test]
90+
[NonParallelizable]
8691
public void SingularCommitsWithHeaderLabelAlias()
8792
{
8893
var config = new Config();
@@ -97,6 +102,7 @@ public void SingularCommitsWithHeaderLabelAlias()
97102
}
98103

99104
[Test]
105+
[NonParallelizable]
100106
public void SingularCommitsWithMilestoneDescription()
101107
{
102108
AcceptTest(1, CreateMilestone("2.4.2", "I am some awesome milestone description."), CreateIssue(5, "Feature"));
@@ -125,6 +131,7 @@ public void SomeCommitsWithoutPluralizedLabelAlias()
125131
}
126132

127133
[Test]
134+
[NonParallelizable]
128135
public void CorrectlyUseFooterWhenEnabled()
129136
{
130137
var config = new Config();
@@ -136,6 +143,7 @@ public void CorrectlyUseFooterWhenEnabled()
136143
}
137144

138145
[Test]
146+
[NonParallelizable]
139147
public void CorrectlyUseFooterWithMilestoneWhenEnabled()
140148
{
141149
var config = new Config();
@@ -178,13 +186,15 @@ public void SomeCommitsMultipleWrongIssueLabel()
178186
}
179187

180188
[Test]
189+
[NonParallelizable]
181190
public void CorrectlyExcludeIssues()
182191
{
183192
AcceptTest(5, CreateIssue(1, "Build"), CreateIssue(2, "Bug"));
184193
Assert.That(true, Is.True); // Just to make sonarlint happy
185194
}
186195

187196
[Test]
197+
[NonParallelizable]
188198
public void CorrectlyExcludeIssuesWhenBothIncludeAndExcludeLabelIsSet()
189199
{
190200
AcceptTest(10, CreateIssue(5, "Improvement", "Build"), CreateIssue(3, "Feature"));

Diff for: src/GitReleaseManager.Tests/ReleaseNotesExporterTests.cs

+2
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ public void SingleRelease()
3434
}
3535

3636
[Test]
37+
[NonParallelizable]
3738
public void SingleReleaseExcludeCreatedDateInTitle()
3839
{
3940
var configuration = ConfigurationProvider.Provide(_currentDirectory, _fileSystem);
@@ -44,6 +45,7 @@ public void SingleReleaseExcludeCreatedDateInTitle()
4445
}
4546

4647
[Test]
48+
[NonParallelizable]
4749
public void SingleReleaseExcludeRegexRemoval()
4850
{
4951
var configuration = ConfigurationProvider.Provide(_currentDirectory, _fileSystem);

Diff for: src/GitReleaseManager.Tool/GitReleaseManager.Tool.csproj

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<OutputType>Exe</OutputType>
44
<AssemblyName>GitReleaseManager</AssemblyName>
55
<PackAsTool>true</PackAsTool>
6-
<TargetFrameworks>net6.0;net7.0</TargetFrameworks>
6+
<TargetFrameworks>net6.0;net7.0;net8.0;net9.0</TargetFrameworks>
77
<ToolCommandName>dotnet-gitreleasemanager</ToolCommandName>
88
<PackageId>GitReleaseManager.Tool</PackageId>
99
<Title>GitReleaseManager Tool</Title>

0 commit comments

Comments
 (0)