test(alarms): advise AlarmExtension diagnostics to discover the alarm source attribute
This commit is contained in:
@@ -380,10 +380,19 @@ public sealed class AlarmSubtagLiveSmokeTests
|
||||
|
||||
// Advise the alarm subtags (InAlarm/Acked/Priority/AckMsg).
|
||||
consumer.Subscribe(string.Format(@"\\{0}\Galaxy!{1}", Environment.MachineName, Group));
|
||||
// Also advise the source attribute so it is an active, writable item
|
||||
// (MXAccess rejects writes to added-but-not-advised items).
|
||||
source.Advise(new List<string> { AlarmSourceTag });
|
||||
Log("Subscribed + advised source. Pumping to activate items ...");
|
||||
// Also advise the source attribute + AlarmExtension diagnostic fields so
|
||||
// we can discover which attribute actually drives the alarm
|
||||
// (AlarmSourceAttr names it) before attempting to write.
|
||||
source.Advise(new List<string>
|
||||
{
|
||||
AlarmSourceTag,
|
||||
AlarmSourceTag + ".AlarmSourceAttr",
|
||||
AlarmSourceTag + ".Condition",
|
||||
AlarmSourceTag + ".AlarmMode",
|
||||
AlarmSourceTag + ".ActiveAlarmState",
|
||||
AlarmSourceTag + ".DescAttrName",
|
||||
});
|
||||
Log("Subscribed + advised source + diagnostics. Pumping to activate items ...");
|
||||
PumpFor(TimeSpan.FromSeconds(7));
|
||||
|
||||
// Baseline OFF: drive the source false and drain whatever transitions
|
||||
|
||||
Reference in New Issue
Block a user