notifyResult();
}
- public void test1() {
+ private void pushTestSetup(String msg) {
+ arrayList.add(msg);
for (int i = 0; i < 100; i++) {
arrayList.add("NO" + i);
}
toListDialog = new ToListDialog(this, arrayList);
+ arrayList.clear();
try {
synchronized (this) {
- wait();
+ wait(30 * 1000);
+ //Wait 30sec
}
} catch (InterruptedException e) {
- System.err.println("Dialg wait interrupted");
- e.printStackTrace();
+ fail("Dialg wait interrupted");
}
+ }
+
+ public void testPushOK() {
+ pushTestSetup("Please push OK button.");
+ assertTrue("Time out or push CANCEL", result);
+ }
+
+ public void testPushCANCEL() {
+ pushTestSetup("Please push CANCEL button.");
+ assertTrue("Time out or push OK", !result);
+ }
+ public void testPushClose() {
+ pushTestSetup("Please close Window.");
+ assertTrue("Time out or push OK", !result);
}
}