test(grpc-data): A1 — the live mark-order test awaits the log, not IsKnown (flaked under load: the fake's alarm write sets known)

This commit is contained in:
Joseph Doherty
2026-11-24 11:45:43 -05:00
parent 72fe8b2454
commit b2ad10c1f0
@@ -36,8 +36,9 @@ public sealed class OpcUaPublishActorConditionKnownTests : RuntimeActorTestBase
actor.Tell(new OpcUaPublishActor.AlarmStateUpdate("al-1", Active, DateTime.UtcNow, AddressSpaceRealm.Uns, Src));
actor.Tell(new OpcUaPublishActor.MarkConditionsKnown(Src, ["al-1"], AddressSpaceRealm.Uns));
AwaitAssert(() => sink.IsKnown("al-1").ShouldBeTrue(), PlanBudget, cancellationToken: TestContext.Current.CancellationToken);
sink.Log.ShouldBe(["alarm:al-1:True", "known:al-1"]);
// Await the LOG, not IsKnown: the fake's alarm write already sets known, so IsKnown could pass before the mark
// landed (observed flaking under load).
AwaitAssert(() => sink.Log.ShouldBe(["alarm:al-1:True", "known:al-1"]), PlanBudget, cancellationToken: TestContext.Current.CancellationToken);
}
/// <summary>T2 (iv) at the publish actor: the apply is artificially delayed (the plan is held open); the alarm and