Public Member Functions | |
StressTest () throws Exception | |
Override void | alarmReceived (AlarmView alarm) |
void | testStress () throws Exception |
Protected Member Functions | |
Override void | setUp () throws Exception |
Override void | tearDown () throws Exception |
Private Member Functions | |
void | send (MiniFaultState mfs) throws Exception |
void | cleanActiveAlarms () throws Exception |
Private Attributes | |
ACSAlarmSystemInterface | alarmSource |
CategoryClient | categoryClient |
MiniFaultState[] | statesToPublish |
int | activeFS = 0 |
HashMap< String, AlarmView > | alarms = new HashMap<StringAlarmView>() |
Static Private Attributes | |
final String | FF = "TEST" |
final String | FM = "Member" |
final int | NUM_ALARMS_TO_SEND = 1000 |
Random | rnd = new Random(System.currentTimeMillis()) |
int | count = 0 |
Sources are not tested here because they have already been tested in laser-source
NOTE: the test is performed without using the CategoryClient that at this level is not available (it requires modules compiled later in the build sequence)
|
Constructor
|
|
|
|
Clean all the active alarms published by the test. This method must be called in the |
|
publish a FaultState
|
|
|
|
|
|
Publishes all the alarms at once then wait until all of them are published by the alarm service. Finally check if the received alarms match with the published fault states. The test is based on active alarms only and discards all the terminated ones. All the published fault states are then compared with alarms received by the alarm service NOTE: The alarm service publishes an active alarm only if its state changes This test works only if the set of alarms it sends is not already present in the alarm service. If it is not the case, the alarm published by the AS depend on the alarms already present in the service. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|