Mir

Merge lp:~vanvugt/mir/fix-1522031 into lp:mir

Proposed by Daniel van Vugt
Status: Work in progress
Proposed branch: lp:~vanvugt/mir/fix-1522031
Merge into: lp:mir
Diff against target: 42 lines (+18/-0)
1 file modified
tests/acceptance-tests/test_latency.cpp (+18/-0)
To merge this branch: bzr merge lp:~vanvugt/mir/fix-1522031
Reviewer Review Type Date Requested Status
Alberto Aguirre (community) Needs Fixing
PS Jenkins bot (community) continuous-integration Approve
Alan Griffiths Disapprove
Alexandros Frantzis (community) Needs Fixing
Review via email: mp+279555@code.launchpad.net

Commit message

Avoid running timing-sensitive performance tests under Valgrind, as
they are likely to fail (and we don't care). (LP: #1522031)

To post a comment you must log in.
Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

We shouldn't block these tests from being run under valgrind if someone wants to do so. I would prefer just to not run them under valgrind for our default test runs.

We can do this by adding the tests to the test_no_memcheck_filter at https://bazaar.launchpad.net/~mir-team/mir/development-branch/view/head:/cmake/MirCommon.cmake#L66

review: Needs Fixing
Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

I wonder though, if these tests should be moved to another suite altogether. Perhaps mir_performance_tests or a new suite?

Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

How can this compile if valgrind isn't installed?

review: Disapprove
Revision history for this message
Alan Griffiths (alan-griffiths) wrote :

> I wonder though, if these tests should be moved to another suite altogether.
> Perhaps mir_performance_tests or a new suite?

Yes, putting performance tests in mir_performance_tests would reduce surprises.

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

Marking tests passed when they don't run seems wrong.

+1 on moving them to mir_performance_tests

review: Needs Fixing

Unmerged revisions

3176. By Daniel van Vugt

Avoid running timing-sensitive performance tests under Valgrind, as
they are likely to fail (and we don't care). (LP: #1522031)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'tests/acceptance-tests/test_latency.cpp'
2--- tests/acceptance-tests/test_latency.cpp 2015-10-20 03:30:00 +0000
3+++ tests/acceptance-tests/test_latency.cpp 2015-12-04 09:24:23 +0000
4@@ -26,6 +26,8 @@
5 #include "mir/test/doubles/null_display_sync_group.h"
6 #include "mir/test/fake_shared.h"
7
8+#include <valgrind/valgrind.h>
9+
10 #include <gtest/gtest.h>
11 #include <gmock/gmock.h>
12 #include <deque>
13@@ -195,6 +197,14 @@
14
15 TEST_F(ClientLatency, triple_buffered_client_uses_all_buffers)
16 {
17+ if (RUNNING_ON_VALGRIND)
18+ {
19+ VALGRIND_PRINTF("Running under valgrind so this real-time "
20+ "multi-process performance test will be skipped "
21+ "(not reliably fast enough to be realistic)\n");
22+ return;
23+ }
24+
25 using namespace testing;
26
27 auto stream = mir_surface_get_buffer_stream(surface);
28@@ -231,6 +241,14 @@
29
30 TEST_F(ClientLatency, throttled_input_rate_yields_lower_latency)
31 {
32+ if (RUNNING_ON_VALGRIND)
33+ {
34+ VALGRIND_PRINTF("Running under valgrind so this real-time "
35+ "multi-process performance test will be skipped "
36+ "(not reliably fast enough to be realistic)\n");
37+ return;
38+ }
39+
40 using namespace testing;
41
42 int const throttled_input_rate = refresh_rate - 1;

Subscribers

People subscribed via source and target branches