]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
tests: Use dbus-run-session instead of dbus-launch
authorMichael Biebl <mbiebl@gmail.com>
Thu, 15 Sep 2016 01:41:00 +0000 (03:41 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Wed, 26 Apr 2017 20:43:46 +0000 (22:43 +0200)
dbus-launch is X11-specific and contains a lot of legacy code to
support X11 autolaunching. It should not be part of the Wayland
future.

Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=836067

https://bugzilla.gnome.org/show_bug.cgi?id=771455

tests/testrunner.sh

index c96655c71e787e0f370ff9b72cebc03ba8fab2f9..f9ff981639920cf4b3f418c2fe1dad21b0e37d59 100755 (executable)
@@ -25,6 +25,7 @@ topbuilddir=$builddir/..
 srcdir=$PWD/`dirname $0`
 topsrcdir=$srcdir/..
 vapidir=$topsrcdir/vapi
+run_prefix=""
 
 export G_DEBUG=fatal_warnings
 
@@ -51,8 +52,7 @@ function testheader() {
                ns=${ns//-/_}
                SOURCEFILE=$ns.vala
        elif [ "$1" = "D-Bus" ]; then
-               echo 'eval `dbus-launch --sh-syntax`' >> prepare
-               echo 'trap "kill $DBUS_SESSION_BUS_PID" INT TERM EXIT' >> prepare
+               run_prefix="dbus-run-session -- $run_prefix"
        elif [ "$1" = "GIR" ]; then
                GIRTEST=1
        fi
@@ -192,7 +192,7 @@ for testfile in "$@"; do
        cat << EOF >> checkall
 echo -n -e "  /$testpath: \033[72G"
 ((all++))
-if bash $ns.check &>log; then
+if $run_prefix bash $ns.check &>log; then
        echo -e "\033[0;32mOK\033[m"
 else
        ((fail++))