* Test activation and deactivation of PersistChanGrpMgrs
*
* @throws Exception
*/
public void testGroupDeactivate() throws Exception {
final PersistChanGrpMgr group1, group2, group3;
group1 = makeEmptyGroup("Activation Group 1");
group2 = makeEmptyGroup("Activation Group 2");
group3 = makeEmptyGroup("Activation Group 3");
addGenChannels(group1, 5, 3);
addGenChannels(group2, 5, 3);
addGenChannels(group3, 5, 3);
assertFalse("expected group 1 to be inactive", group1.isActivated());
assertFalse("expected group 2 to be inactive", group2.isActivated());
assertFalse("expected group 3 to be inactive", group3.isActivated());
group1.activate();
assertTrue("expected group 1 to be active", group1.isActivated());
assertFalse("expected group 2 to be inactive", group2.isActivated());
assertFalse("expected group 3 to be inactive", group3.isActivated());
Thread.sleep(500);
group2.activate();
assertTrue("expected group 1 to be active", group1.isActivated());
assertTrue("expected group 2 to be active", group2.isActivated());
assertFalse("expected group 3 to be inactive", group3.isActivated());
Thread.sleep(500);
group3.activate();
assertTrue("expected group 1 to be active", group1.isActivated());
assertTrue("expected group 2 to be active", group2.isActivated());
assertTrue("expected group 3 to be active", group3.isActivated());
Thread.sleep(500);
group1.deActivate(true);
assertFalse("expected group 1 to be inactive", group1.isActivated());
assertTrue("expected group 2 to be active", group2.isActivated());
assertTrue("expected group 3 to be active", group3.isActivated());
Thread.sleep(500);
group2.deActivate(true);
assertFalse("expected group 1 to be inactive", group1.isActivated());
assertFalse("expected group 2 to be inactive", group2.isActivated());
assertTrue("expected group 3 to be active", group3.isActivated());
Thread.sleep(500);
group3.deActivate(true);
assertFalse("expected group 1 to be inactive", group1.isActivated());
assertFalse("expected group 2 to be inactive", group2.isActivated());
assertFalse("expected group 3 to be inactive", group3.isActivated());
}