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
@@ -23,9 +23,9 @@ namespace ZB.MOM.WW.ScadaBridge.Host.Tests;
/// <para>
/// The replication engine is registered unconditionally and idles, so <c>ISyncStatus</c>
/// still answers <c>Connected=false</c> with a real <c>0</c> backlog. Publishing that pair
/// is the row-80 bug: a dashboard reader sees <c>connected: false</c> on a perfectly healthy
/// is the bug: a dashboard reader sees <c>connected: false</c> on a perfectly healthy
/// unreplicated site and reads a fault, and central's null branches — the conditional KPI
/// emission and the sustained-badge anchor exclusion built for register row 33 — never
/// emission and the sustained-badge anchor exclusion built for unreplicated sites — never
/// receive the null they exist for, so unreplicated sites emitted a misleading
/// <c>localDbReplicationConnected=0</c> series.
/// </para>
@@ -42,6 +42,7 @@ public class UnreplicatedSiteLocalDbHealthTests : IDisposable
private readonly string _tempSiteDbPath;
private readonly string _tempTrackingDbPath;
/// <summary>Builds an unreplicated site host over a temporary LocalDb file.</summary>
public UnreplicatedSiteLocalDbHealthTests()
{
var stamp = Guid.NewGuid();
@@ -79,6 +80,7 @@ public class UnreplicatedSiteLocalDbHealthTests : IDisposable
_host = builder.Build();
}
/// <summary>Releases the resources used by this instance.</summary>
public void Dispose()
{
(_host as IDisposable)?.Dispose();
@@ -90,10 +92,11 @@ public class UnreplicatedSiteLocalDbHealthTests : IDisposable
GC.SuppressFinalize(this);
}
/// <summary>Verifies that an unreplicated site reports null for both LocalDb health fields.</summary>
[Fact]
public void UnreplicatedSite_HealthReport_ReportsNullForBothLocalDbFields()
{
// The row-80 regression, end-to-end through the real container and the real
// The regression, end-to-end through the real container and the real
// collector. Before the fix this produced false/0.
var reporter = _host.Services.GetServices<IHostedService>()
.OfType<LocalDbReplicationStatusReporter>()
@@ -107,6 +110,7 @@ public class UnreplicatedSiteLocalDbHealthTests : IDisposable
Assert.Null(report.LocalDbOplogBacklog);
}
/// <summary>Verifies that an unreplicated site still registers the health bridge.</summary>
[Fact]
public void UnreplicatedSite_StillRegistersTheHealthBridge()
{
@@ -119,10 +123,11 @@ public class UnreplicatedSiteLocalDbHealthTests : IDisposable
Assert.Contains(hosted, h => h is LocalDbReplicationStatusReporter);
}
/// <summary>Verifies that the replication engine of an unreplicated site still resolves and idles.</summary>
[Fact]
public void UnreplicatedSite_ReplicationEngine_StillResolvesAndIdles()
{
// Establishes the premise the row-80 fix rests on: the engine really does answer
// Establishes the premise the fix rests on: the engine really does answer
// false/0 here. If this ever starts returning null on its own, the gate becomes
// redundant rather than wrong — but the test above still pins the observable
// contract either way.