Mir

Merge lp:~vanvugt/mir/untest into lp:mir

Proposed by Daniel van Vugt
Status: Merged
Approved by: Alan Griffiths
Approved revision: no longer in the source branch.
Merged at revision: 1820
Proposed branch: lp:~vanvugt/mir/untest
Merge into: lp:mir
Diff against target: 60 lines (+23/-22)
1 file modified
CMakeLists.txt (+23/-22)
To merge this branch: bzr merge lp:~vanvugt/mir/untest
Reviewer Review Type Date Requested Status
Alan Griffiths Approve
Kevin DuBois (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Alexandros Frantzis (community) Approve
Review via email: mp+229579@code.launchpad.net

Commit message

Remember to honor MIR_ENABLE_TESTS and not emit tests if it's disabled.
(LP: #1352800)

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

Looks good.

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

okay

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

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'CMakeLists.txt'
2--- CMakeLists.txt 2014-08-04 08:51:16 +0000
3+++ CMakeLists.txt 2014-08-05 09:20:55 +0000
4@@ -188,33 +188,34 @@
5
6 option(MIR_ENABLE_TESTS "Build tests" ON)
7
8-if (MIR_ENABLE_TESTS)
9- find_package(Gtest REQUIRED)
10- include_directories(${GMOCK_INCLUDE_DIR} ${GTEST_INCLUDE_DIR})
11- add_subdirectory(tests/)
12-endif ()
13 add_subdirectory(benchmarks/)
14 add_subdirectory(tools/)
15 add_subdirectory(examples/)
16 add_subdirectory(guides/)
17 add_subdirectory(cmake/)
18
19-# There's no nice way to format this. Thanks CMake.
20-add_test(LGPL-required
21- /bin/sh -c "! grep -rl 'GNU General' ${PROJECT_SOURCE_DIR}/src/client ${PROJECT_SOURCE_DIR}/include/client ${PROJECT_SOURCE_DIR}/src/shared ${PROJECT_SOURCE_DIR}/include/shared ${PROJECT_SOURCE_DIR}/src/platform ${PROJECT_SOURCE_DIR}/include/platform"
22-)
23-add_test(GPL-required
24- /bin/sh -c "! grep -rl 'GNU Lesser' ${PROJECT_SOURCE_DIR}/src/server ${PROJECT_SOURCE_DIR}/include/server ${PROJECT_SOURCE_DIR}/include/test ${PROJECT_SOURCE_DIR}/tests ${PROJECT_SOURCE_DIR}/examples"
25-)
26-
27-add_test(NAME server-ABI-unchanged
28- WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
29- COMMAND sha1sum -c server-ABI-sha1sums
30-)
31-
32-add_test(NAME client-ABI-unchanged
33- WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
34- COMMAND sha1sum -c client-ABI-sha1sums
35-)
36+if (MIR_ENABLE_TESTS)
37+ find_package(Gtest REQUIRED)
38+ include_directories(${GMOCK_INCLUDE_DIR} ${GTEST_INCLUDE_DIR})
39+ add_subdirectory(tests/)
40+
41+ # There's no nice way to format this. Thanks CMake.
42+ add_test(LGPL-required
43+ /bin/sh -c "! grep -rl 'GNU General' ${PROJECT_SOURCE_DIR}/src/client ${PROJECT_SOURCE_DIR}/include/client ${PROJECT_SOURCE_DIR}/src/shared ${PROJECT_SOURCE_DIR}/include/shared ${PROJECT_SOURCE_DIR}/src/platform ${PROJECT_SOURCE_DIR}/include/platform"
44+ )
45+ add_test(GPL-required
46+ /bin/sh -c "! grep -rl 'GNU Lesser' ${PROJECT_SOURCE_DIR}/src/server ${PROJECT_SOURCE_DIR}/include/server ${PROJECT_SOURCE_DIR}/include/test ${PROJECT_SOURCE_DIR}/tests ${PROJECT_SOURCE_DIR}/examples"
47+ )
48+
49+ add_test(NAME server-ABI-unchanged
50+ WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
51+ COMMAND sha1sum -c server-ABI-sha1sums
52+ )
53+
54+ add_test(NAME client-ABI-unchanged
55+ WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
56+ COMMAND sha1sum -c client-ABI-sha1sums
57+ )
58+endif ()
59
60 enable_coverage_report(mirserver)

Subscribers

People subscribed via source and target branches