sqlinsight-pro/tests/SQLInsight.Community.Tests/ServerDocsTests.cs
Søren Eggert Lundsteen Olsen 4c2d5252ad Docs: Windows-servere og syntetiske tjek (1.5)
- docs/windows-servere.md: what is collected and how often, how the agent reads
  servers (WS-Man, DCOM fallback, event log over MS-EVEN6), the exact least-privilege
  rights and grant-windows-server.ps1 (never local administrator), known limits,
  "ikke målbar" with the exact reason, firewall ports, the disk forecast, event
  noise filtering, rules with their thresholds, retention, configuration and API.
- docs/syntetiske-tjek.md: the kinds, the AX logon (port, then .NET Business
  Connector in a separate process, or clearly only the port), service running but
  not answering, sealed SQL passwords, rules, firewall, configuration and API.
- Linked from installation, integration (API table) and databehandling (retention,
  nothing sent to the hub); on the website in the documentation index, and the rule
  list shows the Windows server and synthetic check rules in their own areas.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-02 14:59:22 +02:00

33 lines
1.3 KiB
C#

using Microsoft.Extensions.Options;
using SQLInsight.Community.Services;
namespace SQLInsight.Community.Tests;
/// <summary>1.5 on the website: the Windows server and synthetic check documentation and rules.</summary>
public sealed class ServerDocsTests
{
[Fact]
public void The_documentation_has_windows_servers_and_synthetic_checks()
{
var docs = new DocsService(Options.Create(new CommunityOptions()));
var servers = docs.Find("windows-servere");
var checks = docs.Find("syntetiske-tjek");
Assert.Equal("Windows-servere", servers!.Title);
Assert.Contains("aldrig lokal administrator", servers.Html, StringComparison.OrdinalIgnoreCase);
Assert.Contains("grant-windows-server.ps1", servers.Html, StringComparison.Ordinal);
Assert.Contains("5985", servers.Html, StringComparison.Ordinal);
Assert.Equal("Syntetiske tjek", checks!.Title);
Assert.Contains("Kun porten er testet", checks.Html, StringComparison.Ordinal);
}
[Fact]
public void The_rule_list_has_the_windows_server_and_check_rules_in_their_own_areas()
{
var rules = RuleCatalog.All([]);
Assert.Contains(rules, r => r.Id == "SQLI-WIN-006" && r.Area == "Windows-servere");
Assert.Contains(rules, r => r.Id == "SQLI-SYN-001" && r.Area == "Syntetiske tjek");
}
}