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:
@@ -6,7 +6,7 @@ namespace ZB.MOM.WW.ScadaBridge.CentralUI.Tests.Components.Audit;
|
||||
|
||||
/// <summary>
|
||||
/// bUnit tests for <see cref="ExecutionTree"/> (Audit Log ParentExecutionId
|
||||
/// feature, Task 10). The component takes the FLAT
|
||||
/// feature). The component takes the FLAT
|
||||
/// <see cref="ExecutionTreeNode"/> list the repository returns, assembles it
|
||||
/// into a tree by joining <see cref="ExecutionTreeNode.ParentExecutionId"/> to a
|
||||
/// parent node's <see cref="ExecutionTreeNode.ExecutionId"/>, and renders it
|
||||
@@ -35,6 +35,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
rowCount == 0 ? null : new DateTime(2026, 5, 20, 12, 0, 0, DateTimeKind.Utc),
|
||||
rowCount == 0 ? null : new DateTime(2026, 5, 20, 12, 0, 5, DateTimeKind.Utc));
|
||||
|
||||
/// <summary>Verifies that a single node renders as one tree node.</summary>
|
||||
[Fact]
|
||||
public void SingleNode_RendersOneTreeNode()
|
||||
{
|
||||
@@ -48,6 +49,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.Contains($"data-test=\"tree-node-{id}\"", cut.Markup);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a multi-level tree is assembled from the flat node list.</summary>
|
||||
[Fact]
|
||||
public void MultiLevel_AssemblesTree_FromFlatList()
|
||||
{
|
||||
@@ -82,6 +84,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.True(childIdx < grandIdx, "child must render before grandchild");
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a stub node renders with a stub marker.</summary>
|
||||
[Fact]
|
||||
public void StubNode_RendersStubMarker()
|
||||
{
|
||||
@@ -104,6 +107,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.Contains("no audited actions", cut.Markup);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the node the user arrived from is visually highlighted.</summary>
|
||||
[Fact]
|
||||
public void ArrivedFromNode_IsVisuallyHighlighted()
|
||||
{
|
||||
@@ -128,6 +132,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.DoesNotContain("execution-tree-node--current", other.GetAttribute("class") ?? string.Empty);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that each node link points to the audit log filtered by that node's execution.</summary>
|
||||
[Fact]
|
||||
public void NodeLink_PointsTo_AuditLogFilteredByThatExecution()
|
||||
{
|
||||
@@ -154,6 +159,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.Equal($"/audit/log?executionId={root}", rootLink.GetAttribute("href"));
|
||||
}
|
||||
|
||||
/// <summary>Verifies that an empty node list renders nothing and does not throw.</summary>
|
||||
[Fact]
|
||||
public void EmptyNodeList_RendersNothingWithoutThrowing()
|
||||
{
|
||||
@@ -164,6 +170,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.DoesNotContain("data-test=\"tree-node-", cut.Markup);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a cyclic flat list is handled without looping forever.</summary>
|
||||
[Fact]
|
||||
public void CyclicFlatList_TerminatesWithoutInfiniteLoop()
|
||||
{
|
||||
@@ -186,6 +193,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.Equal(1, CountOccurrences(cut.Markup, $"data-test=\"tree-node-{b}\""));
|
||||
}
|
||||
|
||||
/// <summary>Verifies that toggling a node collapses its child subtree and toggling again re-expands it.</summary>
|
||||
[Fact]
|
||||
public void ToggleExpand_CollapsesAndReExpandsChildSubtree()
|
||||
{
|
||||
@@ -229,6 +237,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
cut.Find($"[data-test=\"tree-toggle-{root}\"]").GetAttribute("aria-expanded"));
|
||||
}
|
||||
|
||||
/// <summary>Verifies that double-clicking a node raises <c>OnNodeActivated</c> with that node's execution id.</summary>
|
||||
[Fact]
|
||||
public void DoubleClickingNode_RaisesOnNodeActivated_WithExecutionId()
|
||||
{
|
||||
@@ -255,6 +264,7 @@ public class ExecutionTreeTests : BunitContext
|
||||
Assert.Equal(root, activated);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that double-clicking a nested node bubbles the activation up to the root callback.</summary>
|
||||
[Fact]
|
||||
public void DoubleClickingNestedNode_BubblesOnNodeActivated_ToRoot()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user