Skip to content

Commit 1501281

Browse files
committed
Update two UI tests, add dispose on timeout
1 parent 640428d commit 1501281

2 files changed

Lines changed: 15 additions & 3 deletions

File tree

src/ui/helper/classsearch/ClassSearchFrameTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public void didSelectClass(String classname) {
3030
classSearchFrame.setSize(new Dimension(300, 200));
3131

3232
try {
33-
Thread.sleep(10000);
33+
Thread.sleep(5000);
3434
classSearchFrame.setVisible(false);
3535
classSearchFrame.dispose();
3636
} catch (InterruptedException e) {
@@ -40,7 +40,7 @@ public void didSelectClass(String classname) {
4040
}
4141
});
4242
SwingUtilities.invokeLater(t);
43-
Thread.sleep(100000);
43+
Thread.sleep(10000);
4444

4545

4646
}

src/ui/helper/historyui/HistoryUITest.java

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,21 @@ public void didPressButton(String buttonName, int selectedRow) {
4444
historyUI.setSize(new Dimension(300, 200));
4545

4646

47+
/* Comment below to test the framework */
48+
/* Added for the purpose of continuous integration */
49+
try {
50+
Thread.sleep(5000);
51+
historyUI.dispose();
52+
} catch (InterruptedException e) {
53+
// TODO Auto-generated catch block
54+
e.printStackTrace();
55+
}
56+
57+
58+
4759
}
4860
});
49-
Thread.sleep(Long.MAX_VALUE);
61+
Thread.sleep(10000);
5062
}
5163

5264

0 commit comments

Comments
 (0)