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:
@@ -30,6 +30,7 @@ public class FailoverConfirmLabelTests : BunitContext
|
||||
private readonly IManualFailoverService _failover = Substitute.For<IManualFailoverService>();
|
||||
private readonly DialogService _dialog = new();
|
||||
|
||||
/// <summary>Initializes the bUnit context with an authenticated administrator and substitute failover service.</summary>
|
||||
public FailoverConfirmLabelTests()
|
||||
{
|
||||
var claims = new[]
|
||||
@@ -97,6 +98,8 @@ public class FailoverConfirmLabelTests : BunitContext
|
||||
return host.FindAll("div.modal-footer button").ToList();
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the failover confirm button reads "Fail over" rather than "Delete".</summary>
|
||||
/// <param name="siteId">The site id to fail over, or <see langword="null"/> for the central cluster.</param>
|
||||
[Theory]
|
||||
[InlineData(null)] // central pair
|
||||
[InlineData("SiteA")] // site pair
|
||||
@@ -111,6 +114,7 @@ public class FailoverConfirmLabelTests : BunitContext
|
||||
Assert.Contains("Cancel", footerButtons);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that the failover confirm button keeps its destructive styling.</summary>
|
||||
[Fact]
|
||||
public void Failover_confirm_button_keeps_destructive_styling()
|
||||
{
|
||||
@@ -122,12 +126,14 @@ public class FailoverConfirmLabelTests : BunitContext
|
||||
Assert.Contains("btn-danger", confirm.ClassList);
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a danger confirmation without a custom label still falls back to "Delete".</summary>
|
||||
/// <returns>A task that represents the asynchronous operation.</returns>
|
||||
[Fact]
|
||||
public async Task An_unlabelled_danger_confirm_still_falls_back_to_delete()
|
||||
{
|
||||
// The fallback is retained deliberately: ~20 genuine delete call sites rely
|
||||
// on it (and the Playwright suites click the literal "Delete"). This pins that
|
||||
// the row-28 fix is additive and did not change the default.
|
||||
// the fail-over label fix is additive and did not change the default.
|
||||
var cut = Render<DialogHost>();
|
||||
|
||||
await cut.InvokeAsync(() => { _ = _dialog.ConfirmAsync("Delete thing", "Sure?", danger: true); });
|
||||
|
||||
Reference in New Issue
Block a user