From e96754028c175a88af241e41c7f4f813715ec3ae Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 May 2026 02:22:13 +0000 Subject: [PATCH 1/2] chore: Bump AwesomeAssertions from 8.2.0 to 9.4.0 --- updated-dependencies: - dependency-name: AwesomeAssertions dependency-version: 9.4.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- tests/ExpertiseApi.Tests/ExpertiseApi.Tests.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/ExpertiseApi.Tests/ExpertiseApi.Tests.csproj b/tests/ExpertiseApi.Tests/ExpertiseApi.Tests.csproj index 3d4ec01..da95eb6 100644 --- a/tests/ExpertiseApi.Tests/ExpertiseApi.Tests.csproj +++ b/tests/ExpertiseApi.Tests/ExpertiseApi.Tests.csproj @@ -24,7 +24,7 @@ the original FluentAssertions package (which is now Xceed-commercial v8+) so it cannot re-land here. --> - + runtime; build; native; contentfiles; analyzers; buildtransitive From b714166fe2eb504fd0deb4403f4757bcbcdd2d40 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Mon, 4 May 2026 10:33:45 -0400 Subject: [PATCH 2/2] test: AwesomeAssertions v9 namespace sweep MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit AwesomeAssertions 9.x renamed the namespace from FluentAssertions to AwesomeAssertions. Hoist the import to GlobalUsings.cs and drop the per-file 'using FluentAssertions;' across 18 test files. The previous global usings (Xunit, Microsoft.EntityFrameworkCore) are preserved. This was the deferred follow-up scoped out of PR #114 (the v8.x package rename that closed #98). The Dependabot bump that triggered this PR (Bump AwesomeAssertions 8.2.0 → 9.4.0) carries the v8.x → 9.x package change; this commit completes the namespace migration so the build compiles. Branch was rebased onto current dev to pick up PR7a/PR7b/PR7c (issue #101) before the sweep, so the diff against dev shows only this PR's changes. Validation: - dotnet build: 0 errors, 0 warnings - dotnet test --filter Unit: 86/86 pass - dotnet format analyzers --verify-no-changes: exit 0 --- .../Architecture/DbContextEncapsulationTests.cs | 1 - tests/ExpertiseApi.Tests/GlobalUsings.cs | 4 ++++ tests/ExpertiseApi.Tests/Integration/ApprovalWorkflowTests.cs | 1 - tests/ExpertiseApi.Tests/Integration/AuthEndpointTests.cs | 1 - .../ExpertiseApi.Tests/Integration/ExpertiseEndpointTests.cs | 1 - tests/ExpertiseApi.Tests/Integration/HealthEndpointTests.cs | 1 - .../ExpertiseApi.Tests/Integration/JwtAuthenticationTests.cs | 1 - tests/ExpertiseApi.Tests/Integration/MetricsEndpointTests.cs | 1 - .../Integration/MigrationReversibilityTests.cs | 1 - tests/ExpertiseApi.Tests/Integration/SearchEndpointTests.cs | 1 - tests/ExpertiseApi.Tests/Integration/TenantIsolationTests.cs | 1 - .../ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerLoggingTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/AuthModeStartupGuardTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/CosineDistanceTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/DeduplicationServiceTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/IntegrityHashServiceTests.cs | 1 - tests/ExpertiseApi.Tests/Unit/JwtTenantContextEventsTests.cs | 1 - .../ExpertiseApi.Tests/Unit/ScopeAuthorizationHandlerTests.cs | 1 - 19 files changed, 4 insertions(+), 18 deletions(-) diff --git a/tests/ExpertiseApi.Tests/Architecture/DbContextEncapsulationTests.cs b/tests/ExpertiseApi.Tests/Architecture/DbContextEncapsulationTests.cs index eb71d71..fb5505e 100644 --- a/tests/ExpertiseApi.Tests/Architecture/DbContextEncapsulationTests.cs +++ b/tests/ExpertiseApi.Tests/Architecture/DbContextEncapsulationTests.cs @@ -1,5 +1,4 @@ using ExpertiseApi.Data; -using FluentAssertions; namespace ExpertiseApi.Tests.Architecture; diff --git a/tests/ExpertiseApi.Tests/GlobalUsings.cs b/tests/ExpertiseApi.Tests/GlobalUsings.cs index 3499391..a965a15 100644 --- a/tests/ExpertiseApi.Tests/GlobalUsings.cs +++ b/tests/ExpertiseApi.Tests/GlobalUsings.cs @@ -1,2 +1,6 @@ global using Xunit; global using Microsoft.EntityFrameworkCore; +// AwesomeAssertions 9.x renamed the namespace (`FluentAssertions` → +// `AwesomeAssertions`); hoisting the import here lets every test file drop +// its per-file using and stay namespace-agnostic at the call sites. +global using AwesomeAssertions; diff --git a/tests/ExpertiseApi.Tests/Integration/ApprovalWorkflowTests.cs b/tests/ExpertiseApi.Tests/Integration/ApprovalWorkflowTests.cs index 698cf97..e1a9277 100644 --- a/tests/ExpertiseApi.Tests/Integration/ApprovalWorkflowTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/ApprovalWorkflowTests.cs @@ -5,7 +5,6 @@ using ExpertiseApi.Data; using ExpertiseApi.Models; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.DependencyInjection; diff --git a/tests/ExpertiseApi.Tests/Integration/AuthEndpointTests.cs b/tests/ExpertiseApi.Tests/Integration/AuthEndpointTests.cs index 5cc5d7d..3eeca45 100644 --- a/tests/ExpertiseApi.Tests/Integration/AuthEndpointTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/AuthEndpointTests.cs @@ -1,7 +1,6 @@ using System.Net; using System.Net.Http.Headers; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/ExpertiseEndpointTests.cs b/tests/ExpertiseApi.Tests/Integration/ExpertiseEndpointTests.cs index 7b3d14d..f2d6311 100644 --- a/tests/ExpertiseApi.Tests/Integration/ExpertiseEndpointTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/ExpertiseEndpointTests.cs @@ -4,7 +4,6 @@ using ExpertiseApi.Data; using ExpertiseApi.Models; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; using Microsoft.Extensions.DependencyInjection; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/HealthEndpointTests.cs b/tests/ExpertiseApi.Tests/Integration/HealthEndpointTests.cs index f927f78..e6bd3d4 100644 --- a/tests/ExpertiseApi.Tests/Integration/HealthEndpointTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/HealthEndpointTests.cs @@ -1,7 +1,6 @@ using System.Net; using System.Net.Http.Json; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/JwtAuthenticationTests.cs b/tests/ExpertiseApi.Tests/Integration/JwtAuthenticationTests.cs index e4c1fa3..d21fb5e 100644 --- a/tests/ExpertiseApi.Tests/Integration/JwtAuthenticationTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/JwtAuthenticationTests.cs @@ -1,7 +1,6 @@ using System.Net; using System.Net.Http.Headers; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/MetricsEndpointTests.cs b/tests/ExpertiseApi.Tests/Integration/MetricsEndpointTests.cs index 2d430e1..7cf4679 100644 --- a/tests/ExpertiseApi.Tests/Integration/MetricsEndpointTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/MetricsEndpointTests.cs @@ -1,6 +1,5 @@ using System.Net; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/MigrationReversibilityTests.cs b/tests/ExpertiseApi.Tests/Integration/MigrationReversibilityTests.cs index 731601b..1e2b9dc 100644 --- a/tests/ExpertiseApi.Tests/Integration/MigrationReversibilityTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/MigrationReversibilityTests.cs @@ -1,6 +1,5 @@ using ExpertiseApi.Auth; using ExpertiseApi.Data; -using FluentAssertions; using Microsoft.EntityFrameworkCore; using Microsoft.EntityFrameworkCore.Infrastructure; using Microsoft.EntityFrameworkCore.Migrations; diff --git a/tests/ExpertiseApi.Tests/Integration/SearchEndpointTests.cs b/tests/ExpertiseApi.Tests/Integration/SearchEndpointTests.cs index 2d86e11..c995fba 100644 --- a/tests/ExpertiseApi.Tests/Integration/SearchEndpointTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/SearchEndpointTests.cs @@ -3,7 +3,6 @@ using ExpertiseApi.Data; using ExpertiseApi.Models; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; using Microsoft.Extensions.DependencyInjection; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Integration/TenantIsolationTests.cs b/tests/ExpertiseApi.Tests/Integration/TenantIsolationTests.cs index 10a0ecd..2c1f52c 100644 --- a/tests/ExpertiseApi.Tests/Integration/TenantIsolationTests.cs +++ b/tests/ExpertiseApi.Tests/Integration/TenantIsolationTests.cs @@ -5,7 +5,6 @@ using ExpertiseApi.Data; using ExpertiseApi.Models; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; using Microsoft.Extensions.DependencyInjection; namespace ExpertiseApi.Tests.Integration; diff --git a/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerLoggingTests.cs b/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerLoggingTests.cs index 72beb50..91c2f1e 100644 --- a/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerLoggingTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerLoggingTests.cs @@ -1,6 +1,5 @@ using System.Text.Encodings.Web; using ExpertiseApi.Auth; -using FluentAssertions; using Microsoft.AspNetCore.Authentication; using Microsoft.AspNetCore.Http; using Microsoft.Extensions.Configuration; diff --git a/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerTests.cs b/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerTests.cs index b6c0474..a7d96e0 100644 --- a/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/ApiKeyAuthHandlerTests.cs @@ -1,6 +1,5 @@ using System.Security.Cryptography; using System.Text; -using FluentAssertions; namespace ExpertiseApi.Tests.Unit; diff --git a/tests/ExpertiseApi.Tests/Unit/AuthModeStartupGuardTests.cs b/tests/ExpertiseApi.Tests/Unit/AuthModeStartupGuardTests.cs index 9a370bf..e280810 100644 --- a/tests/ExpertiseApi.Tests/Unit/AuthModeStartupGuardTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/AuthModeStartupGuardTests.cs @@ -1,5 +1,4 @@ using ExpertiseApi.Auth; -using FluentAssertions; using Microsoft.Extensions.Hosting; namespace ExpertiseApi.Tests.Unit; diff --git a/tests/ExpertiseApi.Tests/Unit/CosineDistanceTests.cs b/tests/ExpertiseApi.Tests/Unit/CosineDistanceTests.cs index f21ab91..1c15496 100644 --- a/tests/ExpertiseApi.Tests/Unit/CosineDistanceTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/CosineDistanceTests.cs @@ -1,5 +1,4 @@ using ExpertiseApi.Data; -using FluentAssertions; namespace ExpertiseApi.Tests.Unit; diff --git a/tests/ExpertiseApi.Tests/Unit/DeduplicationServiceTests.cs b/tests/ExpertiseApi.Tests/Unit/DeduplicationServiceTests.cs index 6be1870..6e147c3 100644 --- a/tests/ExpertiseApi.Tests/Unit/DeduplicationServiceTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/DeduplicationServiceTests.cs @@ -4,7 +4,6 @@ using ExpertiseApi.Models; using ExpertiseApi.Services; using ExpertiseApi.Tests.Infrastructure; -using FluentAssertions; using Microsoft.Extensions.Options; using NSubstitute; using Pgvector; diff --git a/tests/ExpertiseApi.Tests/Unit/IntegrityHashServiceTests.cs b/tests/ExpertiseApi.Tests/Unit/IntegrityHashServiceTests.cs index 4b6621e..711af35 100644 --- a/tests/ExpertiseApi.Tests/Unit/IntegrityHashServiceTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/IntegrityHashServiceTests.cs @@ -1,6 +1,5 @@ using ExpertiseApi.Models; using ExpertiseApi.Services; -using FluentAssertions; namespace ExpertiseApi.Tests.Unit; diff --git a/tests/ExpertiseApi.Tests/Unit/JwtTenantContextEventsTests.cs b/tests/ExpertiseApi.Tests/Unit/JwtTenantContextEventsTests.cs index 37d26a7..dc4037e 100644 --- a/tests/ExpertiseApi.Tests/Unit/JwtTenantContextEventsTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/JwtTenantContextEventsTests.cs @@ -1,5 +1,4 @@ using ExpertiseApi.Auth; -using FluentAssertions; namespace ExpertiseApi.Tests.Unit; diff --git a/tests/ExpertiseApi.Tests/Unit/ScopeAuthorizationHandlerTests.cs b/tests/ExpertiseApi.Tests/Unit/ScopeAuthorizationHandlerTests.cs index 8afde28..6a550a0 100644 --- a/tests/ExpertiseApi.Tests/Unit/ScopeAuthorizationHandlerTests.cs +++ b/tests/ExpertiseApi.Tests/Unit/ScopeAuthorizationHandlerTests.cs @@ -1,6 +1,5 @@ using System.Security.Claims; using ExpertiseApi.Auth; -using FluentAssertions; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http;