Skip to content

test: add Tier coverage from PR #94 review#95

Merged
s205109 merged 1 commit intomainfrom
fix/pr94-review-comments
Apr 27, 2026
Merged

test: add Tier coverage from PR #94 review#95
s205109 merged 1 commit intomainfrom
fix/pr94-review-comments

Conversation

@s205109
Copy link
Copy Markdown
Owner

@s205109 s205109 commented Apr 27, 2026

Summary

  • Adds integration tests for RESOURCE_TIER round-trip (GetHealth_WhenResourceTierSet_ReturnsTierInResponse, GetHealth_WhenResourceTierAbsent_ReturnsTierNull)
  • Adds bUnit tests for Tier row visibility when null and known/unknown TierDescription mappings (Health_WhenTierIsNull_DoesNotRenderTierRow, Health_WhenTierIsSet_RendersTierLabel)
  • Fixes HealthResponseBuilder.Build() to use named argument Tier: _tier

Addresses Copilot review comments on #94.

Test plan

  • dotnet test tests/AHKFlowApp.API.Tests --filter HealthControllerTests — 5 tests pass
  • dotnet test tests/AHKFlowApp.UI.Blazor.Tests --filter HealthPageTests — 9 tests pass

🤖 Generated with Claude Code

Integration tests for RESOURCE_TIER round-trip (set/absent).
bUnit tests for Tier row visibility and TierDescription mapping.
Named arg Tier: _tier in HealthResponseBuilder.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

Test Results

2 tests   2 ✅  7s ⏱️
1 suites  0 💤
1 files    0 ❌

Results for commit 5edc1a9.

@github-actions
Copy link
Copy Markdown

Summary

Summary
Generated on: 04/27/2026 - 20:34:34
Coverage date: 04/27/2026 - 20:32:51 - 04/27/2026 - 20:34:31
Parser: MultiReport (10x Cobertura)
Assemblies: 6
Classes: 65
Files: 55
Line coverage: 74.5% (477 of 640)
Covered lines: 477
Uncovered lines: 163
Coverable lines: 640
Total lines: 2226
Branch coverage: 48.2% (69 of 143)
Covered branches: 69
Total branches: 143
Method coverage: Feature is only available for sponsors
Tag: 120_25017988817

Coverage

AHKFlowApp.API - 61.4%
Name Line Branch
AHKFlowApp.API 61.4% 51%
AHKFlowApp.API.Auth.HttpContextCurrentUser 100% 46.1%
AHKFlowApp.API.Auth.TestAuthenticationHandler 100%
AHKFlowApp.API.Controllers.DevController 100%
AHKFlowApp.API.Controllers.HealthController 100%
AHKFlowApp.API.Controllers.HotstringsController 100%
AHKFlowApp.API.Controllers.VersionController 100%
AHKFlowApp.API.Controllers.WhoAmIController 100%
AHKFlowApp.API.DevDockerSqlServer 0% 0%
AHKFlowApp.API.Extensions.ApiExtensions 100%
AHKFlowApp.API.Extensions.ProblemDetailsResultExtensions 100% 100%
AHKFlowApp.API.Middleware.GlobalExceptionMiddleware 100%
AHKFlowApp.API.Models.HealthResponse 100%
AHKFlowApp.API.OpenApi.Examples.CreateHotstringDtoExample 0%
AHKFlowApp.API.OpenApi.Examples.HotstringDtoExample 0%
AHKFlowApp.API.OpenApi.Examples.PagedHotstringsExample 0%
AHKFlowApp.API.OpenApi.Examples.UpdateHotstringDtoExample 0%
AHKFlowApp.Application - 98.1%
Name Line Branch
AHKFlowApp.Application 98.1% 47%
AHKFlowApp.Application.Behaviors.ValidationBehavior`2 100%
AHKFlowApp.Application.Commands.Dev.SeedHotstringsCommandHandler 100%
AHKFlowApp.Application.Commands.Hotstrings.CreateHotstringCommandHandler 66.6% 0%
AHKFlowApp.Application.Commands.Hotstrings.CreateHotstringCommandValidator 100%
AHKFlowApp.Application.Commands.Hotstrings.DeleteHotstringCommandHandler 100%
AHKFlowApp.Application.Commands.Hotstrings.UpdateHotstringCommandHandler 100% 58.3%
AHKFlowApp.Application.Commands.Hotstrings.UpdateHotstringCommandValidator 100%
AHKFlowApp.Application.DependencyInjection 100%
AHKFlowApp.Application.DTOs.CreateHotstringDto 100%
AHKFlowApp.Application.DTOs.HotstringDto 100%
AHKFlowApp.Application.DTOs.PagedList`1 100% 50%
AHKFlowApp.Application.DTOs.UpdateHotstringDto 100%
AHKFlowApp.Application.Mapping.HotstringMappings 100%
AHKFlowApp.Application.Queries.Hotstrings.GetHotstringQueryHandler 100%
AHKFlowApp.Application.Queries.Hotstrings.ListHotstringsQuery 100%
AHKFlowApp.Application.Queries.Hotstrings.ListHotstringsQueryHandler 100%
AHKFlowApp.Application.Queries.Hotstrings.ListHotstringsQueryValidator 100%
AHKFlowApp.Application.Validation.HotstringRules 100% 100%
AHKFlowApp.Domain - 100%
Name Line Branch
AHKFlowApp.Domain 100% ****
AHKFlowApp.Domain.Entities.Hotstring 100%
AHKFlowApp.Infrastructure - 100%
Name Line Branch
AHKFlowApp.Infrastructure 100% 50%
AHKFlowApp.Infrastructure.DependencyInjection 100%
AHKFlowApp.Infrastructure.Persistence.AppDbContext 100%
AHKFlowApp.Infrastructure.Persistence.Configurations.HotstringConfiguration 100%
AHKFlowApp.Infrastructure.Persistence.Configurations.TestMessageConfigurati
on
100%
AHKFlowApp.Infrastructure.Services.VersionService 100% 50%
AHKFlowApp.TestUtilities - 58%
Name Line Branch
AHKFlowApp.TestUtilities 58% 100%
AHKFlowApp.TestUtilities.Auth.TestAuthHandler 100% 100%
AHKFlowApp.TestUtilities.Auth.TestUserBuilder 77.7%
AHKFlowApp.TestUtilities.Builders.HealthResponseBuilder 0%
AHKFlowApp.TestUtilities.Builders.HotstringBuilder 0%
AHKFlowApp.TestUtilities.Fixtures.CustomWebApplicationFactory 100% 100%
AHKFlowApp.TestUtilities.Fixtures.SqlContainerFixture 100%
AHKFlowApp.UI.Blazor - 76%
Name Line Branch
AHKFlowApp.UI.Blazor 76% 36.9%
AHKFlowApp.UI.Blazor.Auth.ApiAuthorizationMessageHandler 0%
AHKFlowApp.UI.Blazor.Auth.TestAuthenticationProvider 0%
AHKFlowApp.UI.Blazor.DTOs.ApiProblemDetails 100%
AHKFlowApp.UI.Blazor.DTOs.CreateHotstringDto 100%
AHKFlowApp.UI.Blazor.DTOs.HealthResponse 100%
AHKFlowApp.UI.Blazor.DTOs.HotstringDto 100%
AHKFlowApp.UI.Blazor.DTOs.PagedList`1 100%
AHKFlowApp.UI.Blazor.DTOs.UpdateHotstringDto 100%
AHKFlowApp.UI.Blazor.Layout.MainLayout 0%
AHKFlowApp.UI.Blazor.Pages.Health 100% 100%
AHKFlowApp.UI.Blazor.Pages.Hotstrings 90.9%
AHKFlowApp.UI.Blazor.Services.AhkFlowAppApiHttpClient 100%
AHKFlowApp.UI.Blazor.Services.ApiErrorMessageFactory 58.3% 26.6%
AHKFlowApp.UI.Blazor.Services.ApiResult 50%
AHKFlowApp.UI.Blazor.Services.ApiResult`1 100%
AHKFlowApp.UI.Blazor.Services.HotstringsApiClient 60% 41.6%
AHKFlowApp.UI.Blazor.Shared.LoginDisplay 0%
AHKFlowApp.UI.Blazor.Shared.RedirectToLogin 0%
AHKFlowApp.UI.Blazor.Validation.HotstringEditModel 100%

Per-assembly thresholds: Domain line≥85% br≥70% · Application line≥85% br≥45% · Infrastructure line≥70% br≥50% · API line≥57% br≥50% · UI.Blazor line≥65% br≥28%

@s205109 s205109 merged commit e9c6c56 into main Apr 27, 2026
3 checks passed
@s205109 s205109 deleted the fix/pr94-review-comments branch April 27, 2026 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant