docs: backfill XML documentation across 756 files
v2-ci / build (push) Failing after 1m43s
v2-ci / unit-tests (tests/Core/ZB.MOM.WW.OtOpcUa.Cluster.Tests) (push) Has been skipped
v2-ci / unit-tests (tests/Server/ZB.MOM.WW.OtOpcUa.ControlPlane.Tests) (push) Has been skipped
v2-ci / unit-tests (tests/Server/ZB.MOM.WW.OtOpcUa.OpcUaServer.Tests) (push) Has been skipped
v2-ci / unit-tests (tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests) (push) Has been skipped
v2-ci / unit-tests (tests/Server/ZB.MOM.WW.OtOpcUa.Security.Tests) (push) Has been skipped
v2-ci / integration (tests/Server/ZB.MOM.WW.OtOpcUa.Host.IntegrationTests) (push) Has been skipped
v2-ci / integration (tests/Server/ZB.MOM.WW.OtOpcUa.OpcUaServer.IntegrationTests) (push) Has been skipped

Adds <summary>, <param>, <typeparam>, and <inheritdoc/> tags to public
members surfaced by commentchecker — resolves 5,847 of 5,869 issues
(99.6%) across three /fixdocs passes.
This commit is contained in:
Joseph Doherty
2026-05-28 08:10:17 -04:00
parent f9fc7dd2e1
commit 64e3fbe035
756 changed files with 9876 additions and 96 deletions
@@ -10,6 +10,7 @@ public sealed class AlarmSurfaceInvokerTests
{
private static readonly DriverResilienceOptions TierAOptions = new() { Tier = DriverTier.A };
/// <summary>Verifies SubscribeAsync on an empty list returns empty without calling the driver.</summary>
[Fact]
public async Task SubscribeAsync_EmptyList_ReturnsEmpty_WithoutDriverCall()
{
@@ -22,6 +23,7 @@ public sealed class AlarmSurfaceInvokerTests
driver.SubscribeCallCount.ShouldBe(0);
}
/// <summary>Verifies SubscribeAsync with no resolver routes through the default host.</summary>
[Fact]
public async Task SubscribeAsync_SingleHost_RoutesThroughDefaultHost()
{
@@ -35,6 +37,7 @@ public sealed class AlarmSurfaceInvokerTests
driver.LastSubscribedIds.ShouldBe(["src-1", "src-2"]);
}
/// <summary>Verifies SubscribeAsync fans out correctly to multiple hosts based on resolver.</summary>
[Fact]
public async Task SubscribeAsync_MultiHost_FansOutByResolvedHost()
{
@@ -53,6 +56,7 @@ public sealed class AlarmSurfaceInvokerTests
driver.SubscribeCallCount.ShouldBe(2); // one driver call per host
}
/// <summary>Verifies AcknowledgeAsync does not retry on failure.</summary>
[Fact]
public async Task AcknowledgeAsync_DoesNotRetry_OnFailure()
{
@@ -65,6 +69,7 @@ public sealed class AlarmSurfaceInvokerTests
driver.AcknowledgeCallCount.ShouldBe(1, "AlarmAcknowledge must not retry — decision #143");
}
/// <summary>Verifies SubscribeAsync retries on transient failures.</summary>
[Fact]
public async Task SubscribeAsync_Retries_Transient_Failures()
{
@@ -106,6 +111,7 @@ public sealed class AlarmSurfaceInvokerTests
driver.UnsubscribeCallCount.ShouldBe(2, "one unsubscribe per subscription handle (per host)");
}
/// <summary>Verifies UnsubscribeAsync with no resolver uses the default host.</summary>
[Fact]
public async Task UnsubscribeAsync_SingleHost_UsesDefaultHost()
{
@@ -131,15 +137,31 @@ public sealed class AlarmSurfaceInvokerTests
return new AlarmSurfaceInvoker(invoker, driver, defaultHost, resolver);
}
/// <summary>Fake alarm source for testing.</summary>
private sealed class FakeAlarmSource : IAlarmSource
{
/// <summary>Gets the number of times SubscribeAlarmsAsync was called.</summary>
public int SubscribeCallCount { get; private set; }
/// <summary>Gets the number of times UnsubscribeAlarmsAsync was called.</summary>
public int UnsubscribeCallCount { get; private set; }
/// <summary>Gets the number of times AcknowledgeAsync was called.</summary>
public int AcknowledgeCallCount { get; private set; }
/// <summary>Gets or sets the number of failures before SubscribeAlarmsAsync succeeds.</summary>
public int SubscribeFailuresBeforeSuccess { get; set; }
/// <summary>Gets or sets whether AcknowledgeAsync should throw.</summary>
public bool AcknowledgeShouldThrow { get; set; }
/// <summary>Gets the source node IDs from the most recent SubscribeAlarmsAsync call.</summary>
public IReadOnlyList<string> LastSubscribedIds { get; private set; } = [];
/// <summary>Subscribes to alarms.</summary>
/// <param name="sourceNodeIds">The source node IDs to subscribe to.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>An alarm subscription handle.</returns>
public Task<IAlarmSubscriptionHandle> SubscribeAlarmsAsync(
IReadOnlyList<string> sourceNodeIds, CancellationToken cancellationToken)
{
@@ -150,12 +172,20 @@ public sealed class AlarmSurfaceInvokerTests
return Task.FromResult<IAlarmSubscriptionHandle>(new StubHandle($"h-{SubscribeCallCount}"));
}
/// <summary>Unsubscribes from alarms.</summary>
/// <param name="handle">The subscription handle to unsubscribe.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A completed task.</returns>
public Task UnsubscribeAlarmsAsync(IAlarmSubscriptionHandle handle, CancellationToken cancellationToken)
{
UnsubscribeCallCount++;
return Task.CompletedTask;
}
/// <summary>Acknowledges alarms.</summary>
/// <param name="acknowledgements">The alarm acknowledgements to process.</param>
/// <param name="cancellationToken">Cancellation token.</param>
/// <returns>A completed task.</returns>
public Task AcknowledgeAsync(
IReadOnlyList<AlarmAcknowledgeRequest> acknowledgements, CancellationToken cancellationToken)
{
@@ -164,13 +194,21 @@ public sealed class AlarmSurfaceInvokerTests
return Task.CompletedTask;
}
/// <summary>Occurs when an alarm event is raised.</summary>
public event EventHandler<AlarmEventArgs>? OnAlarmEvent { add { } remove { } }
}
/// <summary>Stub alarm subscription handle for testing.</summary>
/// <param name="DiagnosticId">Diagnostic identifier for the handle.</param>
private sealed record StubHandle(string DiagnosticId) : IAlarmSubscriptionHandle;
/// <summary>Stub host resolver for testing multi-host scenarios.</summary>
/// <param name="map">The map of source node IDs to host names.</param>
private sealed class StubResolver(Dictionary<string, string> map) : IPerCallHostResolver
{
/// <summary>Resolves the host for the given full reference.</summary>
/// <param name="fullReference">The full reference to resolve.</param>
/// <returns>The resolved host name.</returns>
public string ResolveHost(string fullReference) => map[fullReference];
}
}