Merge lp:~townsend/unity/fix-icon-loader-test into lp:unity

Proposed by Christopher Townsend
Status: Merged
Approved by: Brandon Schaefer
Approved revision: no longer in the source branch.
Merged at revision: 3508
Proposed branch: lp:~townsend/unity/fix-icon-loader-test
Merge into: lp:unity
Diff against target: 39 lines (+5/-3)
1 file modified
tests/test_icon_loader.cpp (+5/-3)
To merge this branch: bzr merge lp:~townsend/unity/fix-icon-loader-test
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Brandon Schaefer (community) Approve
Review via email: mp+185880@code.launchpad.net

Commit message

Set the wait timeout to a longer period (1000ms) since many Jenkins CI tests are failing in the TestIconLoader tests.

Description of the change

= Issue =
Up to 3 TestIconLoader unit tests fail intermittently due the the 500ms default timeout elapsing during CI. It appears the Jenkins server may be under some sort of load when these tests fail.

= Fix =
For now, try increasing the timeout to 1000ms in hopes that this will get the test to complete. This timeout may need to be adjusted if the tests still fail.

To post a comment you must log in.
Revision history for this message
Brandon Schaefer (brandontschaefer) wrote :

LGTM

review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/test_icon_loader.cpp'
2--- tests/test_icon_loader.cpp 2013-08-27 13:25:09 +0000
3+++ tests/test_icon_loader.cpp 2013-09-16 17:59:57 +0000
4@@ -28,6 +28,8 @@
5
6 namespace
7 {
8+const int WAIT_TIMEOUT = 1000;
9+
10 bool IsValidPixbuf(GdkPixbuf *pixbuf)
11 {
12 return GDK_IS_PIXBUF (pixbuf);
13@@ -116,7 +118,7 @@
14 &LoadResult::IconLoaded));
15 handles_.push_back(handle);
16
17- Utils::WaitUntilMSec(load_result.got_callback);
18+ Utils::WaitUntilMSec(load_result.got_callback, WAIT_TIMEOUT);
19 EXPECT_TRUE(load_result.got_callback);
20 EXPECT_TRUE(IsValidPixbuf(load_result.pixbuf));
21 }
22@@ -129,7 +131,7 @@
23 &LoadResult::IconLoaded));
24 handles_.push_back(handle);
25
26- Utils::WaitUntilMSec(load_result.got_callback);
27+ Utils::WaitUntilMSec(load_result.got_callback, WAIT_TIMEOUT);
28 EXPECT_TRUE(load_result.got_callback);
29 EXPECT_TRUE(IsValidPixbuf(load_result.pixbuf));
30 }
31@@ -142,7 +144,7 @@
32 &LoadResult::IconLoaded));
33 handles_.push_back(handle);
34
35- Utils::WaitUntilMSec(load_result.got_callback);
36+ Utils::WaitUntilMSec(load_result.got_callback, WAIT_TIMEOUT);
37 EXPECT_TRUE(load_result.got_callback);
38 EXPECT_TRUE(IsValidPixbuf(load_result.pixbuf));
39 }