From 19f44e5ff3756172540e768fc0d08d761f0c374e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sun, 6 Dec 2020 10:50:13 +0100 Subject: tests: Wait for the dcop server to be ready. Use a separate ICEAUTHORITY for tests. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko --- tdeio/tests/CMakeLists.txt | 1 + tdeio/tests/kmimetypetest.sh.cmake | 5 +++++ 2 files changed, 6 insertions(+) (limited to 'tdeio') diff --git a/tdeio/tests/CMakeLists.txt b/tdeio/tests/CMakeLists.txt index 323a7d86e..e9f5ea5ff 100644 --- a/tdeio/tests/CMakeLists.txt +++ b/tdeio/tests/CMakeLists.txt @@ -80,6 +80,7 @@ configure_file( kmimetypetest.sh.cmake kmimetypetest.sh @ONLY ) add_test( NAME "tdeio/kmimetypetest" COMMAND sh -x "${CMAKE_CURRENT_BINARY_DIR}/kmimetypetest.sh" WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" ) +set_tests_properties( "tdeio/kmimetypetest" PROPERTIES TIMEOUT 30) # TODO add kdirwatchunittest diff --git a/tdeio/tests/kmimetypetest.sh.cmake b/tdeio/tests/kmimetypetest.sh.cmake index 3bcd98669..55a0ffbc6 100644 --- a/tdeio/tests/kmimetypetest.sh.cmake +++ b/tdeio/tests/kmimetypetest.sh.cmake @@ -5,11 +5,16 @@ HOME=@CMAKE_CURRENT_BINARY_DIR@/test-home mkdir $HOME $HOME/.trinity $HOME/.trinity/share ln -s @CMAKE_SOURCE_DIR@/mimetypes $HOME/.trinity/share/mimelnk export HOME +export ICEAUTHORITY=$HOME/.ICEauthority # run dcop server ../../dcop/dcopserver --nofork & DCOP_SERVER_PID=$! +while ! ../../dcop/dcopserver --serverid 2>/dev/null; do + sleep 2 +done + # update tdesycoca using mime types from source ../../kded/tdebuildsycoca --noincremental --nosignal -- cgit v1.2.1