diff options
-rw-r--r-- | gr-qtgui/python/qtgui/CMakeLists.txt | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gr-qtgui/python/qtgui/CMakeLists.txt b/gr-qtgui/python/qtgui/CMakeLists.txt index 09031cbc36..b7c4817e7d 100644 --- a/gr-qtgui/python/qtgui/CMakeLists.txt +++ b/gr-qtgui/python/qtgui/CMakeLists.txt @@ -46,11 +46,18 @@ if(ENABLE_TESTING) ${CMAKE_BINARY_DIR}/gnuradio-runtime/python ) + if(LINUX AND NOT DEFINED ENV{DISPLAY}) + find_program(XVFB_EXECUTABLE xvfb-run) + if(XVFB_EXECUTABLE) + set(QA_DISPLAY_SERVER "${XVFB_EXECUTABLE}") + endif() + endif() + include(GrTest) file(GLOB py_qa_test_files "qa_*.py") foreach(py_qa_test_file ${py_qa_test_files}) get_filename_component(py_qa_test_name ${py_qa_test_file} NAME_WE) - GR_ADD_TEST(${py_qa_test_name} ${QA_PYTHON_EXECUTABLE} -B ${py_qa_test_file}) + GR_ADD_TEST(${py_qa_test_name} ${QA_DISPLAY_SERVER} ${QA_PYTHON_EXECUTABLE} -B ${py_qa_test_file}) endforeach(py_qa_test_file) endif(ENABLE_TESTING) |