fix(r2-06): warning parity — malformed-endpoint warning in ServerHistorianOptions.Validate() (06/S-11)

This commit is contained in:
Joseph Doherty
2026-07-13 09:57:29 -04:00
parent e748f929c8
commit b77bbd13b7
3 changed files with 28 additions and 2 deletions
@@ -21,6 +21,16 @@ public sealed class ServerHistorianOptionsTests
Assert.Contains(w, m => m.Contains("Endpoint"));
}
[Fact]
public void Enabled_with_malformed_endpoint_warns()
{
// archreview 06/S-11 warning parity: a non-empty but unparseable / non-absolute Endpoint warns
// too, so the Runtime-side registration logs describe malformed endpoints (not just empty ones),
// keeping this surface consistent with the Host's fail-fast ServerHistorianOptionsValidator.
var w = new ServerHistorianOptions { Enabled = true, Endpoint = "not a uri", ApiKey = "histgw_x_y" }.Validate();
Assert.Contains(w, m => m.Contains("Endpoint"));
}
[Fact]
public void Enabled_without_apikey_warns()
{