Skip to content

Commit

Permalink
Use .NET 9
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyrrrz committed Nov 12, 2024
1 parent 36b2b07 commit f5ff619
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
with:
deploy: ${{ inputs.deploy || github.ref_type == 'tag' }}
package-version: ${{ inputs.package-version || (github.ref_type == 'tag' && github.ref_name) || format('0.0.0-ci-{0}', github.sha) }}
dotnet-version: 8.0.x
dotnet-version: 9.0.x
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
NUGET_TOKEN: ${{ secrets.NUGET_TOKEN }}
Expand Down
2 changes: 1 addition & 1 deletion CliFx.Analyzers.Tests/CliFx.Analyzers.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion CliFx.Benchmarks/CliFx.Benchmarks.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion CliFx.Demo/CliFx.Demo.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<ApplicationIcon>../favicon.ico</ApplicationIcon>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion CliFx.Tests.Dummy/CliFx.Tests.Dummy.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
<ApplicationIcon>../favicon.ico</ApplicationIcon>
</PropertyGroup>

Expand Down
2 changes: 1 addition & 1 deletion CliFx.Tests/CliFx.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<TargetFramework>net9.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
Expand Down
5 changes: 1 addition & 4 deletions CliFx.Tests/Utils/Extensions/AssertionExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,13 @@ internal static class AssertionExtensions
{
public static void ConsistOfLines(
this StringAssertions assertions,
IEnumerable<string> lines
params IEnumerable<string> lines
) =>
assertions
.Subject.Split(new[] { '\n', '\r' }, StringSplitOptions.RemoveEmptyEntries)
.Should()
.Equal(lines);

public static void ConsistOfLines(this StringAssertions assertions, params string[] lines) =>
assertions.ConsistOfLines((IEnumerable<string>)lines);

public static AndConstraint<StringAssertions> ContainAllInOrder(
this StringAssertions assertions,
IEnumerable<string> values
Expand Down
5 changes: 1 addition & 4 deletions CliFx/Utils/Disposable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,10 @@ internal partial class Disposable
{
public static IDisposable Create(Action dispose) => new Disposable(dispose);

public static IDisposable Merge(IEnumerable<IDisposable> disposables) =>
public static IDisposable Merge(params IEnumerable<IDisposable> disposables) =>
Create(() =>
{
foreach (var disposable in disposables)
disposable.Dispose();
});

public static IDisposable Merge(params IDisposable[] disposables) =>
Merge((IEnumerable<IDisposable>)disposables);
}

0 comments on commit f5ff619

Please sign in to comment.