test: update ReportPlanGate test for maxDays signature
CI/CD / CI · API (dotnet build + test) (push) Successful in 41s
CI/CD / CI · Admin API (dotnet build) (push) Successful in 32s
CI/CD / CI · Dashboard (tsc) (push) Successful in 1m5s
CI/CD / CI · Admin Web (tsc) (push) Successful in 38s
CI/CD / CI · Website (tsc) (push) Successful in 44s
CI/CD / CI · Koja (tsc) (push) Successful in 50s
CI/CD / Deploy · all services (push) Successful in 1m32s

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
soroush.asadi
2026-06-03 07:00:49 +03:30
parent e46d833371
commit 45dab8b253
@@ -196,8 +196,9 @@ public class DailyReportServiceTests
public void ReportPlanGate_Free_AllowsEightDayWindow() public void ReportPlanGate_Free_AllowsEightDayWindow()
{ {
var today = new DateOnly(2026, 5, 21); var today = new DateOnly(2026, 5, 21);
Assert.True(ReportPlanGate.IsDateInRange(PlanTier.Free, today, today)); const int freeMaxDays = 8; // Free plan's report-history window
Assert.True(ReportPlanGate.IsDateInRange(PlanTier.Free, today.AddDays(-7), today)); Assert.True(ReportPlanGate.IsDateInRange(freeMaxDays, today, today));
Assert.False(ReportPlanGate.IsDateInRange(PlanTier.Free, today.AddDays(-8), today)); Assert.True(ReportPlanGate.IsDateInRange(freeMaxDays, today.AddDays(-7), today));
Assert.False(ReportPlanGate.IsDateInRange(freeMaxDays, today.AddDays(-8), today));
} }
} }