From 3891657d19f512e79b683c961f5b39339ec1854e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 02:53:07 +0000 Subject: [PATCH 1/2] chore: Bump the minor-and-patch group with 5 updates Bumps Microsoft.Extensions.Http from 9.0.9 to 9.0.10 Bumps Microsoft.Testing.Platform from 1.9.0 to 2.0.1 Bumps Spectre.Console from 0.52.0 to 0.53.0 Bumps Spectre.Console.Cli from 0.52.0 to 0.53.0 Bumps Spectre.Console.Json from 0.52.0 to 0.53.0 --- updated-dependencies: - dependency-name: Microsoft.Extensions.Http dependency-version: 9.0.10 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: Microsoft.Extensions.Http dependency-version: 9.0.10 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: Microsoft.Testing.Platform dependency-version: 2.0.1 dependency-type: direct:production update-type: version-update:semver-major dependency-group: minor-and-patch - dependency-name: Spectre.Console dependency-version: 0.53.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: Spectre.Console.Cli dependency-version: 0.53.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: Spectre.Console.Json dependency-version: 0.53.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch ... Signed-off-by: dependabot[bot] --- .../SwedishTestSsn.Core.Test.csproj | 4 ++-- src/SwedishTestSsn.Core/SwedishTestSsn.Core.csproj | 2 +- src/SwedishTestSsn/SwedishTestSsn.csproj | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj b/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj index 8afaee7..16f4759 100644 --- a/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj +++ b/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj @@ -27,9 +27,9 @@ - + - + diff --git a/src/SwedishTestSsn.Core/SwedishTestSsn.Core.csproj b/src/SwedishTestSsn.Core/SwedishTestSsn.Core.csproj index 7f478ef..703dd27 100644 --- a/src/SwedishTestSsn.Core/SwedishTestSsn.Core.csproj +++ b/src/SwedishTestSsn.Core/SwedishTestSsn.Core.csproj @@ -7,7 +7,7 @@ - + diff --git a/src/SwedishTestSsn/SwedishTestSsn.csproj b/src/SwedishTestSsn/SwedishTestSsn.csproj index 5d6a6bd..1f9382c 100644 --- a/src/SwedishTestSsn/SwedishTestSsn.csproj +++ b/src/SwedishTestSsn/SwedishTestSsn.csproj @@ -34,9 +34,9 @@ - - - + + + From 9d1e88a70479845bb05670c822fa6c4ba7cc9f3f Mon Sep 17 00:00:00 2001 From: Ferenyl Date: Mon, 27 Oct 2025 16:20:46 +0100 Subject: [PATCH 2/2] Update packages --- SwedishTestSsn.sln | 4 +- .../SwedishTestSsn.Core.Test.csproj | 6 +-- src/SwedishTestSsn/TestSsnCommand.cs | 48 +++++++++---------- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/SwedishTestSsn.sln b/SwedishTestSsn.sln index ea0becc..2fe3b0a 100644 --- a/SwedishTestSsn.sln +++ b/SwedishTestSsn.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.0.31903.59 +# Visual Studio Version 18 +VisualStudioVersion = 18.0.11018.127 d18.0 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SwedishTestSsn.Core", "src\SwedishTestSsn.Core\SwedishTestSsn.Core.csproj", "{36271D9E-465A-4CD3-BF0B-A6E866D8C5E1}" EndProject diff --git a/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj b/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj index 16f4759..51d5bcd 100644 --- a/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj +++ b/src/SwedishTestSsn.Core.Test/SwedishTestSsn.Core.Test.csproj @@ -28,16 +28,16 @@ - - - + + true true + diff --git a/src/SwedishTestSsn/TestSsnCommand.cs b/src/SwedishTestSsn/TestSsnCommand.cs index 21b9fbc..4f84ae6 100644 --- a/src/SwedishTestSsn/TestSsnCommand.cs +++ b/src/SwedishTestSsn/TestSsnCommand.cs @@ -53,29 +53,7 @@ public TestSsnCommand() : base() _ssnClient = new Client(_client); } - public override async Task ExecuteAsync( - [NotNull] CommandContext context, - [NotNull] Settings settings) - { - var result = await GetData(settings); - - if (result.Length == 0) - { - AnsiConsole.MarkupLine($"[red]No result for pattern: {settings.Pattern}[/]"); - return 1; - } - - if (settings.Json) - { - PrintJson(result); - } - else - { - PrintText(result); - } - - return 0; - } + private static void PrintText(ImmutableArray result) { @@ -106,5 +84,27 @@ private async Task> GetData(Settings settings) AnsiConsole.MarkupLine($"[red]Error with skatteverket api[/]"); return []; } - } + } + + public override async Task ExecuteAsync(CommandContext context, Settings settings, CancellationToken cancellationToken) + { + var result = await GetData(settings); + + if (result.Length == 0) + { + AnsiConsole.MarkupLine($"[red]No result for pattern: {settings.Pattern}[/]"); + return 1; + } + + if (settings.Json) + { + PrintJson(result); + } + else + { + PrintText(result); + } + + return 0; + } }