docs(tests): fix CommentChecker findings across tests/ — 13,392 → 0 (repo-wide scan clean)

Comment/XML-doc changes only:
- add summaries to ~10k test methods, fixtures, fakes and helpers
  (+ <param> on theories, <returns> on async Task methods,
  <inheritdoc/> on interface implementations the checker can resolve)
- strip ~2.6k project-tracking references (WP*, P*-*, row-NN, Task N,
  #NN, Component-0NN) from comments, keeping the explanatory text;
  reword false positives in comments only
- real docs on fakes implementing BCL/library interfaces
  (IDisposable, ILogger, IOptionsMonitor, IAsyncLifetime)
- reword the last 5 src/ false positives (CWE-1236, failures-1,
  year-0001, M365)

Only non-comment edits: four one-line nested classes split across lines
so members can carry docs. Build 0 errors / 0 warnings.
This commit is contained in:
Joseph Doherty
2026-10-07 15:05:49 -04:00
parent 0ffd4bdbea
commit 513fa1aa16
998 changed files with 17896 additions and 2395 deletions
@@ -6,7 +6,7 @@ using ZB.MOM.WW.ScadaBridge.Security;
namespace ZB.MOM.WW.ScadaBridge.IntegrationTests;
/// <summary>
/// WP-1 (Phase 8): Full-system failover testing — Central.
/// Full-system failover testing — Central.
/// Verifies that JWT tokens and deployment state survive central node failover.
/// Multi-process failover tests are marked with Integration trait for separate runs.
/// </summary>
@@ -24,6 +24,7 @@ public class CentralFailoverTests
return new JwtTokenService(options, NullLogger<JwtTokenService>.Instance);
}
/// <summary>Verifies that a JWT generated before failover validates after failover.</summary>
[Fact]
public void JwtToken_GeneratedBeforeFailover_ValidatesAfterFailover()
{
@@ -46,6 +47,7 @@ public class CentralFailoverTests
Assert.Equal("failover_test", username);
}
/// <summary>Verifies that a JWT with site scopes survives revalidation.</summary>
[Fact]
public void JwtToken_WithSiteScopes_SurvivesRevalidation()
{
@@ -67,6 +69,7 @@ public class CentralFailoverTests
Assert.Contains("site-5", siteIds);
}
/// <summary>Verifies that a JWT validated with a different signing key fails validation.</summary>
[Fact]
public void JwtToken_DifferentSigningKeys_FailsValidation()
{
@@ -85,6 +88,7 @@ public class CentralFailoverTests
Assert.Null(principal);
}
/// <summary>Verifies that optimistic concurrency on deployment status detects stale writes.</summary>
[Trait("Category", "Integration")]
[Fact]
public void DeploymentStatus_OptimisticConcurrency_DetectsStaleWrites()
@@ -101,6 +105,7 @@ public class CentralFailoverTests
Assert.Equal(Commons.Types.Enums.DeploymentStatus.Success, status2.Status);
}
/// <summary>Verifies that a JWT that expired before failover is rejected after failover.</summary>
[Fact]
public void JwtToken_ExpiredBeforeFailover_RejectedAfterFailover()
{
@@ -119,6 +124,7 @@ public class CentralFailoverTests
Assert.NotNull(expClaim);
}
/// <summary>Verifies that an idle timeout is detected.</summary>
[Fact]
public void JwtToken_IdleTimeout_Detected()
{
@@ -137,6 +143,7 @@ public class CentralFailoverTests
Assert.False(jwtService.IsIdleTimedOut(principal!));
}
/// <summary>Verifies that the refresh check detects a token near expiry.</summary>
[Fact]
public void JwtToken_ShouldRefresh_DetectsNearExpiry()
{
@@ -155,6 +162,7 @@ public class CentralFailoverTests
Assert.False(jwtService.ShouldRefresh(principal!));
}
/// <summary>Verifies that deployment status for multiple instances is tracked independently.</summary>
[Trait("Category", "Integration")]
[Fact]
public void DeploymentStatus_MultipleInstances_IndependentTracking()