Fix settings log tail reads
PR and Push Build/Test / build-and-test (push) Failing after 12m50s

This commit is contained in:
2026-05-30 14:25:35 +02:00
parent 0342cff64f
commit fd8c33f1ea
3 changed files with 35 additions and 8 deletions
@@ -155,15 +155,18 @@ public sealed class WorkflowRulesEditorTests
new MeetingAssistantOptions(),
logDirectory: root);
using var provider = new MeetingAssistantFileLoggerProvider(root);
provider.CreateLogger("Test").LogInformation("locked needle");
var tail = await tools.ReadLogs(tail: 2);
var range = await tools.ReadLogs(from: 2, to: 2);
var range = await tools.ReadLogs(from: 1, to: 1);
var search = await tools.SearchLogs("needle");
Assert.DoesNotContain("first line", tail);
Assert.Contains("second needle", tail);
Assert.Equal("second needle", range.Trim());
Assert.Contains("meeting-assistant.log:2 second needle", search);
Assert.Contains("meeting-assistant.log.1:1 rotated needle", search);
Assert.Contains("locked needle", tail);
Assert.Contains("locked needle", search);
Assert.Contains("locked needle", range);
Assert.Contains("meeting-assistant.log:1", search);
Assert.Contains("meeting-assistant.log.2:1 rotated needle", search);
}
[Fact]