docs(src): add missing XML docs and strip tracking-ID comments
Sweep of 203 source files resolving CommentChecker findings: add <summary>/<param>/<returns>/<inheritdoc> where missing, and remove resolved task/issue tracking markers (Tests-NNN, Worker-NNN, Server-NNN, Task N) from code comments. Comment/doc-only — no logic changes. Server+Tests build clean under TreatWarningsAsErrors.
This commit is contained in:
@@ -9,16 +9,6 @@ namespace ZB.MOM.WW.MxGateway.Tests.Galaxy;
|
||||
/// <summary>
|
||||
/// Adversarial-input coverage for the Galaxy Repository browse filter layer.
|
||||
/// <para>
|
||||
/// Re-triage note (finding Tests-002): the Galaxy Repository's SQL surface
|
||||
/// (<c>HierarchySql</c>, <c>AttributesSql</c>, <c>SELECT 1</c>,
|
||||
/// <c>SELECT time_of_last_deploy FROM galaxy</c>) is entirely constant — no
|
||||
/// <see cref="DiscoverHierarchyRequest"/> field is ever concatenated into a SQL
|
||||
/// string. All filters (<c>TagNameGlob</c>, <c>RootTagName</c>, category ids,
|
||||
/// template-chain filters, contained-path roots) are applied in memory by
|
||||
/// <see cref="GalaxyHierarchyProjector"/> against the cached snapshot, so there is
|
||||
/// no SQL-injection surface and no <c>LIKE</c>-escaping helper to test.
|
||||
/// </para>
|
||||
/// <para>
|
||||
/// The genuine, testable concern is that adversarial filter strings — SQL
|
||||
/// metacharacters (<c>'</c>, <c>;</c>) and <c>LIKE</c>-wildcards (<c>%</c>,
|
||||
/// <c>_</c>) — are treated as opaque literals by the in-memory filter layer:
|
||||
@@ -41,6 +31,7 @@ public sealed class GalaxyFilterInputSafetyTests
|
||||
];
|
||||
|
||||
/// <summary>Returns adversarial input cases for theory tests.</summary>
|
||||
/// <returns>Theory data of adversarial input strings.</returns>
|
||||
public static TheoryData<string> AdversarialInputCases()
|
||||
{
|
||||
TheoryData<string> data = [];
|
||||
@@ -88,7 +79,7 @@ public sealed class GalaxyFilterInputSafetyTests
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Regression guard for finding Server-008: <see cref="GalaxyGlobMatcher"/> caches
|
||||
/// <see cref="GalaxyGlobMatcher"/> caches
|
||||
/// the compiled regex per glob pattern. Repeated calls with the same pattern, and
|
||||
/// interleaved calls with different patterns, must keep returning the correct
|
||||
/// literal-vs-wildcard result rather than a stale cached match.
|
||||
@@ -229,6 +220,7 @@ public sealed class GalaxyFilterInputSafetyTests
|
||||
/// zero matches rather than returning the whole hierarchy or faulting.
|
||||
/// </summary>
|
||||
/// <param name="glob">An adversarial glob containing SQL metacharacters or LIKE wildcards.</param>
|
||||
/// <returns>A task that represents the asynchronous operation.</returns>
|
||||
[Theory]
|
||||
[MemberData(nameof(AdversarialInputCases))]
|
||||
public async Task DiscoverHierarchy_WithAdversarialTagNameGlob_ReturnsZeroMatches(string glob)
|
||||
@@ -249,6 +241,7 @@ public sealed class GalaxyFilterInputSafetyTests
|
||||
/// a query fragment or matching unrelated objects.
|
||||
/// </summary>
|
||||
/// <param name="rootTagName">An adversarial tag name containing SQL metacharacters or LIKE wildcards.</param>
|
||||
/// <returns>A task that represents the asynchronous operation.</returns>
|
||||
[Theory]
|
||||
[MemberData(nameof(AdversarialInputCases))]
|
||||
public async Task DiscoverHierarchy_WithAdversarialRootTagName_ReturnsNotFound(string rootTagName)
|
||||
@@ -327,13 +320,17 @@ public sealed class GalaxyFilterInputSafetyTests
|
||||
|
||||
private sealed class StubGalaxyHierarchyCache(GalaxyHierarchyCacheEntry current) : IGalaxyHierarchyCache
|
||||
{
|
||||
/// <inheritdoc />
|
||||
/// <summary>Gets the fixed cache entry returned to callers.</summary>
|
||||
public GalaxyHierarchyCacheEntry Current { get; } = current;
|
||||
|
||||
/// <inheritdoc />
|
||||
/// <summary>Does nothing; the stub never refreshes.</summary>
|
||||
/// <param name="cancellationToken">Cancellation token.</param>
|
||||
/// <returns>A task that represents the asynchronous operation.</returns>
|
||||
public Task RefreshAsync(CancellationToken cancellationToken) => Task.CompletedTask;
|
||||
|
||||
/// <inheritdoc />
|
||||
/// <summary>Does nothing; the stub is always considered loaded.</summary>
|
||||
/// <param name="cancellationToken">Cancellation token.</param>
|
||||
/// <returns>A task that represents the asynchronous operation.</returns>
|
||||
public Task WaitForFirstLoadAsync(CancellationToken cancellationToken) => Task.CompletedTask;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user