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:
@@ -1,10 +1,13 @@
|
||||
namespace ZB.MOM.WW.ScadaBridge.NotificationService.Tests;
|
||||
|
||||
/// <summary>
|
||||
/// NS-005: Tests for parsing the configured SMTP TLS mode into the three-state enum.
|
||||
/// Tests for parsing the configured SMTP TLS mode into the three-state enum.
|
||||
/// </summary>
|
||||
public class SmtpTlsModeParserTests
|
||||
{
|
||||
/// <summary>Verifies that a known mode string parses to the expected TLS mode.</summary>
|
||||
/// <param name="input">The configured mode string.</param>
|
||||
/// <param name="expected">The expected parsed TLS mode.</param>
|
||||
[Theory]
|
||||
[InlineData("none", SmtpTlsMode.None)]
|
||||
[InlineData("None", SmtpTlsMode.None)]
|
||||
@@ -19,6 +22,8 @@ public class SmtpTlsModeParserTests
|
||||
Assert.Equal(expected, SmtpTlsModeParser.Parse(input));
|
||||
}
|
||||
|
||||
/// <summary>Verifies that a null or empty mode defaults to StartTLS.</summary>
|
||||
/// <param name="input">The null or empty mode string.</param>
|
||||
[Theory]
|
||||
[InlineData(null)]
|
||||
[InlineData("")]
|
||||
@@ -28,13 +33,15 @@ public class SmtpTlsModeParserTests
|
||||
Assert.Equal(SmtpTlsMode.StartTls, SmtpTlsModeParser.Parse(input));
|
||||
}
|
||||
|
||||
/// <summary>Verifies that an unknown mode string throws.</summary>
|
||||
/// <param name="input">The unrecognized mode string.</param>
|
||||
[Theory]
|
||||
[InlineData("auto")]
|
||||
[InlineData("tls")]
|
||||
[InlineData("implicit")]
|
||||
public void Parse_UnknownMode_Throws(string input)
|
||||
{
|
||||
// NS-005: an unknown mode must be rejected, not silently treated as Auto.
|
||||
// An unknown mode must be rejected, not silently treated as Auto.
|
||||
Assert.Throws<ArgumentException>(() => SmtpTlsModeParser.Parse(input));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user