summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/CTestCustom.template6
-rwxr-xr-xtests/virtualfb.sh5
2 files changed, 7 insertions, 4 deletions
diff --git a/tests/CTestCustom.template b/tests/CTestCustom.template
index 72e6443..0e51e21 100644
--- a/tests/CTestCustom.template
+++ b/tests/CTestCustom.template
@@ -37,8 +37,10 @@ if( __cmake_system_name__ MATCHES "Linux|BSD")
message("Process ID of vfb: ${VFB_PID}")
endif()
if ("${VFB_DISPLAY}" STREQUAL "" OR "${VFB_PID}" STREQUAL "")
- message("Virtual framebuffer had a problem starting.")
- execute_process("cat virtualfblog")
+ set(VFBLOG "virtualfb.log")
+ message("Virtual framebuffer had a problem starting. Printing ${VFBLOG}")
+ execute_process(COMMAND cat virtualfb.log OUTPUT_VARIABLE VFBLOGTXT)
+ message("Log: ${VFBLOGTXT}")
else()
message("Virtual framebuffer started. DISPLAY=${VFB_DISPLAY}, PID=${VFB_PID}")
endif()
diff --git a/tests/virtualfb.sh b/tests/virtualfb.sh
index 3c0cf0e..e745765 100755
--- a/tests/virtualfb.sh
+++ b/tests/virtualfb.sh
@@ -13,8 +13,9 @@ if [ ! $VFB_BINARY ]; then
exit 1
fi
-DISPLAY=:98
-$VFB_BINARY $DISPLAY -screen 0 800x600x24 &> virtualfblog &
+DISPLAY=`echo | awk 'BEGIN{srand();} {printf ":%.0f", rand()*1000+100};'`
+#DISPLAY=:98
+$VFB_BINARY $DISPLAY -screen 0 800x600x24 &> virtualfb.log &
echo PID=$! " "
echo DISPLAY=$DISPLAY
# trap "kill -KILL $xpid ||:" EXIT
contact: Jan Huwald // Impressum