chore(uns): create-redirect null guard + alarm isolation test + alarm-authoring doc (final review)

This commit is contained in:
Joseph Doherty
2026-06-11 15:23:06 -04:00
parent a0f3f4ab89
commit 80b19d6fc8
3 changed files with 18 additions and 0 deletions
@@ -86,4 +86,17 @@ public sealed class UnsTreeServiceScriptedAlarmTests
dup.Error.ShouldNotBeNull();
dup.Error!.ShouldContain("already exists");
}
[Fact]
public async Task LoadAlarmsForEquipment_excludes_other_equipment()
{
var svc = SeededService();
await svc.CreateScriptedAlarmAsync(UnsTreeTestDb.SeededEquipmentId, Sample("SA-MINE"));
await svc.CreateScriptedAlarmAsync("EQ-OTHER", Sample("SA-OTHER") with { Name = "Other-alarm" });
var rows = await svc.LoadAlarmsForEquipmentAsync(UnsTreeTestDb.SeededEquipmentId);
rows.Count.ShouldBe(1);
rows[0].ScriptedAlarmId.ShouldBe("SA-MINE");
}
}