System.out.println("new AckCollector: " + ac);
}
public void testReset2() throws TimeoutException {
final AckCollector ac=new AckCollector(list);
final Address six=Util.createRandomAddress("six"), seven=Util.createRandomAddress("seven"),
eight=Util.createRandomAddress("eight");
final List<Address> new_list=Arrays.asList(six, seven, eight);
new Thread() {
public void run() {
Util.sleep(500);
System.out.println("resetting AckCollector");
ac.reset(new_list);
System.out.println("reset AckCollector: " + ac);
Util.sleep(100);
ac.ack(six);
System.out.println("AckCollector: " + ac);
Util.sleep(100);
ac.ack(seven);
System.out.println("AckCollector: " + ac);
Util.sleep(100);
ac.ack(eight);
System.out.println("AckCollector: " + ac);
}
}.start();
System.out.println("initial AckCollector: " + ac);
ac.waitForAllAcks(30000);
System.out.println("new AckCollector: " + ac);
}