Fix: Sync Log und verwaise Einträge
CI / build-and-test (push) Canceled after 0s

This commit is contained in:
2026-09-07 17:09:38 +02:00
parent 835cccadec
commit 86e114580f
12 changed files with 145 additions and 12 deletions
@@ -61,7 +61,7 @@ public sealed class UntisSyncServiceTests
}
[Fact]
public void ProcessIcsText_AbweichendesFach_SchreibtVertretungUndAktualisiertBeiWiederholung()
public void ProcessIcsText_AbweichendesFach_SchreibtVertretungUndUeberspringtUnveraenderteWiederholung()
{
var mappings = new FakeUntisSlotMappings();
mappings.Add(new UntisSlotMapping
@@ -81,7 +81,7 @@ public sealed class UntisSyncServiceTests
// Eintrag erzeugen - Idempotenz über SubstitutionEntry.ExternalId.
var second = service.ProcessIcsText(BuildIcs("1", "20260817T075000", "NAT", "10c HED"));
Assert.Equal(1, second.SubstitutionCount);
Assert.Equal(0, second.SubstitutionCount);
Assert.Single(substitutions.GetAll());
}
@@ -278,7 +278,7 @@ public sealed class UntisSyncServiceTests
// Erneuter Poll mit demselben, weiterhin unverändert vorhandenen Termin darf keinen
// zweiten Eintrag erzeugen (Idempotenz über ExternalId=Uid).
var second = service.ProcessIcsText(BuildIcs("v1", dtstart, null, "HED"));
Assert.Equal(1, second.SubstitutionCount);
Assert.Equal(0, second.SubstitutionCount);
Assert.Single(substitutions.GetAll());
}