on xenial help sign in
apply same to tests not added by that macro
commit45af6fed8067d6bf0acc93a0d80c01b7c5d22c8e authorMichael Zanetti <michael.zanetti@canonical.com> dateTue 18 Mar 2014, 14:23 (13 years ago) parenta68674a
2 files changed+26−2
tests/plugins/Ubuntu/Gestures/CMakeLists.txt+13−1 tests/qmltests/Components/CMakeLists.txt+13−1
tests/plugins/Ubuntu/Gestures/CMakeLists.txt+13−1
@@ -22,9 +22,21 @@ macro(add_gesture_ui_test CLASSNAME)
2222 -o -,txt)
2323
2424 add_custom_target(test${CLASSNAME} ${testCommand})
25− add_dependencies(qmluitests test${CLASSNAME})
2625 add_dependencies(test${CLASSNAME} ${CLASSNAME}TestExec UbuntuGesturesTestQmlFiles)
2726
27+ set(xvfbtestCommand
28+ LD_PRELOAD=/usr/lib/x86_64-linux-gnu/mesa/libGL.so.1
29+ LD_LIBRARY_PATH=${CMAKE_BINARY_DIR}/plugins/Ubuntu/Gestures
30+ xvfb-run --server-args "-screen 0 1024x768x24" --auto-servernum
31+ ${CMAKE_CURRENT_BINARY_DIR}/${CLASSNAME}TestExec
32+ -o ${CMAKE_BINARY_DIR}/${CLASSNAME}Test.xml,xunitxml
33+ -o -,txt)
34+
35+ add_custom_target(xvfbtest${CLASSNAME} ${xvfbtestCommand})
36+ add_dependencies(test${CLASSNAME} ${CLASSNAME}TestExec UbuntuGesturesTestQmlFiles)
37+
38+ add_dependencies(qmluitests xvfbtest${CLASSNAME})
39+
2840 add_executable(${CLASSNAME}TestExec tst_${CLASSNAME}.cpp GestureTest.cpp)
2941 qt5_use_modules(${CLASSNAME}TestExec Test Core Qml Gui Quick)
3042 target_link_libraries(${CLASSNAME}TestExec UbuntuGestureQml)
tests/qmltests/Components/CMakeLists.txt+13−1
@@ -13,9 +13,21 @@ set(testCommand
1313 -o -,txt)
1414
1515add_custom_target(testDragHandle ${testCommand})
16−add_dependencies(qmluitests testDragHandle)
1716add_dependencies(testDragHandle DragHandleTestExec)
1817
18+set(xvfbtestCommand
19+ LD_PRELOAD=/usr/lib/x86_64-linux-gnu/mesa/libGL.so.1
20+ LD_LIBRARY_PATH=${CMAKE_BINARY_DIR}/plugins/Ubuntu/Gestures
21+ xvfb-run --server-args "-screen 0 1024x768x24" --auto-servernum
22+ ${CMAKE_CURRENT_BINARY_DIR}/DragHandleTestExec
23+ -o ${CMAKE_BINARY_DIR}/DragHandleTest.xml,xunitxml
24+ -o -,txt)
25+
26+add_custom_target(xvfbtestDragHandle ${xvfbtestCommand})
27+add_dependencies(xvfbtestDragHandle DragHandleTestExec)
28+
29+add_dependencies(qmluitests xvfbtestDragHandle)
30+
1931add_executable(DragHandleTestExec tst_DragHandle.cpp)
2032qt5_use_modules(DragHandleTestExec Test Core Qml Gui Quick)
2133target_link_libraries(DragHandleTestExec UbuntuGestureQml)