diff --git a/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmInitialStateSignalTests.cs b/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmInitialStateSignalTests.cs
new file mode 100644
index 000000000..e6a900a16
--- /dev/null
+++ b/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmInitialStateSignalTests.cs
@@ -0,0 +1,115 @@
+using Shouldly;
+using Xunit;
+using ZB.MOM.WW.OtOpcUa.Commons.OpcUa;
+using ZB.MOM.WW.OtOpcUa.Core.Abstractions;
+using ZB.MOM.WW.OtOpcUa.Runtime.OpcUa;
+
+namespace ZB.MOM.WW.OtOpcUa.Runtime.Tests.Drivers;
+
+///
+/// A1 (plan §5.1 T1/T2/F2/F5/G5) — the native "standing alarms delivered" signal through the real
+/// DriverInstanceActor → DriverHostActor chain, against a fake driver. Asserts on the order the publish
+/// actor receives the alarm projections and the that summarises
+/// them.
+///
+[Trait("Feature", "GrpcData")]
+[Trait("Phase", "A1")]
+[Trait("Category", "Unit")]
+public sealed class NativeAlarmInitialStateSignalTests : NativeAlarmSignalTestBase
+{
+ private static readonly string A = RawPathOf("hi");
+ private static readonly string B = RawPathOf("lo");
+ private static CancellationToken Ct => TestContext.Current.CancellationToken;
+
+ [Fact]
+ public void Conditions_become_known_only_on_the_signal_and_after_the_projection_it_covers()
+ {
+ var rig = StartRig(DriverTypeNames.Galaxy, ["hi", "lo"]);
+
+ rig.Driver.Raise(A).ShouldBeTrue();
+ rig.Publish.FishForMessage(u => u.AlarmNodeId == A, TimeSpan.FromSeconds(5), cancellationToken: TestContext.Current.CancellationToken)
+ .Source.ShouldBe(DriverId);
+ // Negative control: the replay is not a signal — nothing is marked known yet.
+ AssertNoMark(rig.Publish, TimeSpan.FromMilliseconds(300));
+
+ rig.Driver.Signal([A, B]).ShouldBeTrue();
+ var mark = rig.Publish.FishForMessage(_ => true, TimeSpan.FromSeconds(5), cancellationToken: TestContext.Current.CancellationToken);
+ mark.Source.ShouldBe(DriverId);
+ mark.Realm.ShouldBe(AddressSpaceRealm.Raw);
+ mark.ConditionIds.ShouldBe([A, B], ignoreOrder: true);
+ }
+
+ /// T2 (iv), Galaxy-shaped, artificially delayed: the snapshot + sentinel are raised while the
+ /// DriverInstanceActor's mailbox is held (its alarm subscribe is still awaiting), so every message queues behind it;
+ /// the mark still reaches the publish actor after the Active projection it summarises.
+ [Fact]
+ public void A_delayed_driver_actor_still_delivers_the_mark_after_the_snapshot_projections()
+ {
+ var driver = new FakeSignallingAlarmDriver(DriverId, DriverTypeNames.Galaxy) { SubscribeDelay = TimeSpan.FromMilliseconds(800) };
+ driver.OnSubscribed = d => d.ReplaySnapshot([A]);
+ var rig = StartRig(DriverTypeNames.Galaxy, ["hi", "lo"], driver: driver);
+
+ var traffic = CollectAlarmTraffic(rig.Publish, m => m is OpcUaPublishActor.MarkConditionsKnown);
+ var activeAt = traffic.FindIndex(m => m is OpcUaPublishActor.AlarmStateUpdate { State.Active: true } u && u.AlarmNodeId == A);
+ activeAt.ShouldBeGreaterThanOrEqualTo(0);
+ activeAt.ShouldBeLessThan(traffic.Count - 1); // the mark is last
+ ((OpcUaPublishActor.MarkConditionsKnown)traffic[^1]).ConditionIds.ShouldBe([A, B], ignoreOrder: true);
+ }
+
+ /// T2 (v) F5: a signal that never completes ⇒ after the timeout the conditions are still unknown (no mark),
+ /// the diagnostic is raised, and a late signal marks them and clears it.
+ [Fact]
+ public void A_signal_that_never_completes_raises_the_diagnostic_and_a_late_signal_clears_it()
+ {
+ var rig = StartRig(DriverTypeNames.Galaxy, ["hi", "lo"],
+ o => o.WithSignalTimeout(DriverTypeNames.Galaxy, TimeSpan.FromMilliseconds(300)));
+
+ AwaitCondition(() => rig.Hub.Unsignalled.ContainsKey(DriverId), TimeSpan.FromSeconds(5), Ct);
+ rig.Hub.Unsignalled[DriverId].Conditions.ShouldBe(2);
+ AssertNoMark(rig.Publish, TimeSpan.FromMilliseconds(200)); // never known-inactive
+
+ rig.Driver.Signal([A, B]);
+ rig.Publish.FishForMessage(_ => true, TimeSpan.FromSeconds(5), cancellationToken: TestContext.Current.CancellationToken);
+ AwaitCondition(() => !rig.Hub.Unsignalled.ContainsKey(DriverId), TimeSpan.FromSeconds(5), Ct);
+ }
+
+ /// The OpcUaClient-only backstop: an unsignalable report is marked known after the settle window from
+ /// quality Good — not at once.
+ [Fact]
+ public void An_unsignalable_OpcUaClient_subscription_is_known_after_the_backstop()
+ {
+ var rig = StartRig(DriverTypeNames.OpcUaClient, ["hi"], o => o.WithOpcUaClientSettle(TimeSpan.FromMilliseconds(1500)));
+ rig.Driver.Signal([A], unsignalable: true);
+
+ AssertNoMark(rig.Publish, TimeSpan.FromMilliseconds(300)); // not immediately
+ var mark = rig.Publish.FishForMessage(_ => true, TimeSpan.FromSeconds(5), cancellationToken: TestContext.Current.CancellationToken);
+ mark.ConditionIds.ShouldBe([A]);
+ }
+
+ [Fact]
+ public void Another_driver_type_has_no_backstop_and_stays_unknown()
+ {
+ var rig = StartRig(DriverTypeNames.Galaxy, ["hi"]);
+ rig.Driver.Signal([A], unsignalable: true);
+ AssertNoMark(rig.Publish, TimeSpan.FromMilliseconds(800));
+ }
+
+ /// T2 (xi) G5: a signal raised while the feed is suppressed (no alarm subscription) is not delivered; after
+ /// subscribe the first signal follows the replayed standing alarms.
+ [Fact]
+ public void A_suppressed_signal_is_not_delivered_and_the_first_signal_follows_the_replay()
+ {
+ var driver = new FakeSignallingAlarmDriver(DriverId, DriverTypeNames.Galaxy);
+ driver.Signal([A]).ShouldBeFalse("no alarm subscription yet: the gate OnAlarmEvent obeys");
+ driver.OnSubscribed = d => d.ReplaySnapshot([A]);
+ var rig = StartRig(DriverTypeNames.Galaxy, ["hi", "lo"], driver: driver);
+
+ var traffic = CollectAlarmTraffic(rig.Publish, m => m is OpcUaPublishActor.MarkConditionsKnown);
+ traffic.OfType().Count().ShouldBe(1);
+ traffic[0].ShouldBeOfType().AlarmNodeId.ShouldBe(A);
+
+ rig.Driver.Unsubscribe();
+ rig.Driver.Signal([A, B]).ShouldBeFalse();
+ AssertNoMark(rig.Publish, TimeSpan.FromMilliseconds(300));
+ }
+}
diff --git a/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmSignalTestBase.cs b/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmSignalTestBase.cs
new file mode 100644
index 000000000..f3c09d527
--- /dev/null
+++ b/tests/Server/ZB.MOM.WW.OtOpcUa.Runtime.Tests/Drivers/NativeAlarmSignalTestBase.cs
@@ -0,0 +1,265 @@
+using System.Text.Json;
+using Akka.Actor;
+using Akka.TestKit;
+using Microsoft.EntityFrameworkCore;
+using Shouldly;
+using Xunit;
+using ZB.MOM.WW.OtOpcUa.Commons.Engines;
+using ZB.MOM.WW.OtOpcUa.Commons.Messages.Deploy;
+using ZB.MOM.WW.OtOpcUa.Commons.OpcUa;
+using ZB.MOM.WW.OtOpcUa.Commons.Types;
+using ZB.MOM.WW.OtOpcUa.Configuration;
+using ZB.MOM.WW.OtOpcUa.Configuration.Entities;
+using ZB.MOM.WW.OtOpcUa.Configuration.Enums;
+using ZB.MOM.WW.OtOpcUa.Core.Abstractions;
+using ZB.MOM.WW.OtOpcUa.Runtime.DataConnections;
+using ZB.MOM.WW.OtOpcUa.Runtime.Drivers;
+using ZB.MOM.WW.OtOpcUa.Runtime.OpcUa;
+using ZB.MOM.WW.OtOpcUa.Runtime.Tests.Harness;
+
+namespace ZB.MOM.WW.OtOpcUa.Runtime.Tests.Drivers;
+
+///
+/// A1 (plan §5.1) reusable rig for native "standing alarms delivered" signal tests: a real
+/// + real around a
+/// , with the OPC UA publish actor replaced by a probe so the exact order of
+/// and is
+/// observable. The driver agent's per-driver tests (ii, iii, vi–ix) inherit this and swap the fake for each real
+/// driver's shape.
+///
+public abstract class NativeAlarmSignalTestBase : RuntimeActorTestBase
+{
+ /// The driver instance id the rig deploys.
+ protected const string DriverId = "drv-sig";
+ private static readonly NodeId RigNode = NodeId.Parse("a1-signal-rig");
+ private static readonly RevisionHash Rev = RevisionHash.Parse(new string('c', 64));
+
+ /// The RawPath of alarm tag under the rig's folder/driver/device.
+ /// The tag name.
+ /// The RawPath (= the driver ConditionId = the condition NodeId).
+ protected static string RawPathOf(string tag) => $"Plant/Drv/dev1/{tag}";
+
+ /// One started rig.
+ /// The driver host.
+ /// The publish-actor probe (rebuild already drained).
+ /// The fake driver the host spawned.
+ /// The hub the F5 diagnostic is raised on.
+ protected sealed record Rig(IActorRef Host, TestProbe Publish, FakeSignallingAlarmDriver Driver, ConditionStateHub Hub);
+
+ /// Deploys as native alarm tags of one enabled driver of
+ /// , waits for the apply, the driver's connection and its alarm subscription.
+ /// The driver type (decides the backstop / F5 timeout).
+ /// The alarm tag names.
+ /// Adjusts the signal options (timeouts).
+ /// A pre-built fake (e.g. with a subscribe delay), or null for a default one.
+ /// The rig.
+ protected Rig StartRig(string driverType, IReadOnlyList alarmTags,
+ Func? configure = null, FakeSignallingAlarmDriver? driver = null)
+ {
+ var db = NewInMemoryDbFactory();
+ var deploymentId = Seed(db, driverType, alarmTags);
+ driver ??= new FakeSignallingAlarmDriver(DriverId, driverType);
+ var hub = new ConditionStateHub();
+ var options = new ConditionSignalOptions { Hub = hub };
+ options = configure?.Invoke(options) ?? options;
+
+ var coordinator = CreateTestProbe();
+ var publish = this.CreateCleanOutcomePublishProbe();
+ var host = Sys.ActorOf(DriverHostActor.Props(
+ db, RigNode, coordinator.Ref,
+ driverFactory: new SingleDriverFactory(driver),
+ localRoles: new HashSet { "driver" },
+ dependencyMux: CreateTestProbe().Ref,
+ opcUaPublishActor: publish.Ref,
+ virtualTagEvaluator: NullVirtualTagEvaluator.Instance,
+ virtualTagHostOverride: CreateTestProbe().Ref,
+ conditionSignals: options));
+
+ host.Tell(new DispatchDeployment(deploymentId, Rev, CorrelationId.NewId()));
+ coordinator.FishForMessage(_ => true, TimeSpan.FromSeconds(10), cancellationToken: TestContext.Current.CancellationToken).Outcome.ShouldBe(ApplyAckOutcome.Applied);
+ AwaitCondition(() => driver.Subscribed, TimeSpan.FromSeconds(10), TestContext.Current.CancellationToken);
+ return new Rig(host, publish, driver, hub);
+ }
+
+ /// Negative control: for , the probe receives no
+ /// (other traffic — quality annotations — is ignored).
+ /// The probe.
+ /// How long to watch.
+ protected static void AssertNoMark(TestProbe publish, TimeSpan duration)
+ {
+ var deadline = DateTime.UtcNow + duration;
+ while (DateTime.UtcNow < deadline)
+ {
+ var m = publish.ReceiveOne(deadline - DateTime.UtcNow);
+ if (m is OpcUaPublishActor.MarkConditionsKnown mark)
+ throw new ShouldAssertException($"unexpected MarkConditionsKnown({string.Join(",", mark.ConditionIds)})");
+ }
+ }
+
+ /// The publish-actor messages that are alarm-state updates or marks, in arrival order, until
+ /// matches (inclusive).
+ /// The probe.
+ /// Stop condition.
+ /// Overall wait.
+ /// The ordered messages.
+ protected static List