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:
+12
-3
@@ -14,7 +14,7 @@ using ZB.MOM.WW.ScadaBridge.NotificationOutbox.Tests.TestSupport;
|
||||
namespace ZB.MOM.WW.ScadaBridge.NotificationOutbox.Tests;
|
||||
|
||||
/// <summary>
|
||||
/// Task 13: Tests for the <see cref="NotificationOutboxActor"/> ingest path — building a
|
||||
/// Tests for the <see cref="NotificationOutboxActor"/> ingest path — building a
|
||||
/// <see cref="Notification"/> from a <see cref="NotificationSubmit"/>, persisting it via
|
||||
/// <see cref="INotificationOutboxRepository.InsertIfNotExistsAsync"/>, and acking the sender.
|
||||
/// </summary>
|
||||
@@ -59,6 +59,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
SourceNode: sourceNode);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a notification submit persists the mapped notification and acks it as accepted.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_PersistsMappedNotification_AndAcksAccepted()
|
||||
{
|
||||
@@ -90,10 +91,11 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the origin execution id is copied onto the persisted notification.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_CopiesOriginExecutionId_OntoPersistedNotification()
|
||||
{
|
||||
// Audit Log #23: the originating script execution's id rides on the
|
||||
// The originating script execution's id rides on the
|
||||
// NotificationSubmit and must be persisted on the Notification row so
|
||||
// the dispatcher can later echo it onto NotifyDeliver audit rows.
|
||||
_repository.InsertIfNotExistsAsync(Arg.Any<Notification>(), Arg.Any<CancellationToken>())
|
||||
@@ -110,6 +112,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a null origin execution id is persisted as null.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_NullOriginExecutionId_PersistsNull()
|
||||
{
|
||||
@@ -126,6 +129,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the origin parent execution id is copied onto the persisted notification.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_CopiesOriginParentExecutionId_OntoPersistedNotification()
|
||||
{
|
||||
@@ -146,6 +150,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a null origin parent execution id is persisted as null.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_NullOriginParentExecutionId_PersistsNull()
|
||||
{
|
||||
@@ -162,6 +167,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a duplicate submit, where the repository returns false, is still acked as accepted.</summary>
|
||||
[Fact]
|
||||
public void DuplicateSubmit_RepositoryReturnsFalse_StillAcksAccepted()
|
||||
{
|
||||
@@ -178,6 +184,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Assert.Null(ack.Error);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a repository exception results in an ack that is not accepted and carries the error.</summary>
|
||||
[Fact]
|
||||
public void RepositoryThrows_AcksNotAcceptedWithError()
|
||||
{
|
||||
@@ -195,10 +202,11 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Assert.Contains("database unavailable", ack.Error);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the source node is copied onto the persisted notification.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_CopiesSourceNode_OntoPersistedNotification()
|
||||
{
|
||||
// SourceNode-stamping (Task 13): the originating site's node name (node-a/node-b)
|
||||
// SourceNode stamping: the originating site's node name (node-a/node-b)
|
||||
// rides on the NotificationSubmit and must be persisted on the Notification row so
|
||||
// central observers (KPIs, audit drill-ins, ops dashboards) can see which node
|
||||
// emitted the notification.
|
||||
@@ -215,6 +223,7 @@ public class NotificationOutboxActorIngestTests : TestKit
|
||||
Arg.Any<CancellationToken>());
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a null source node is persisted as null.</summary>
|
||||
[Fact]
|
||||
public void NotificationSubmit_NullSourceNode_PersistsNull()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user