ci: Only launch a single mocked D-Bus environment for all tests

This cuts away a lot of time wasted on spawning and tearing down D-Bus
daemons and mocked service for every test case.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2678>
This commit is contained in:
Jonas Ådahl 2022-10-28 15:50:10 +02:00 committed by Marge Bot
parent ec18a1d7ae
commit 1b65fedc9b
2 changed files with 13 additions and 15 deletions

View File

@ -367,8 +367,12 @@ build-without-native-backend-and-wayland@x86_64:
- .test-mutter-base
script:
- glib-compile-schemas $GSETTINGS_SCHEMA_DIR
- dbus-run-session -- xvfb-run -a -s "$XVFB_SERVER_ARGS"
./.gitlab-ci/run-meson.sh test -C build
- xvfb-run -a -s "$XVFB_SERVER_ARGS"
./src/tests/meta-dbus-runner.py
--launch=wireplumber
meson test
-C build
--setup plain
--no-suite 'mutter/kvm'
--no-rebuild
--timeout-multiplier 10
@ -495,8 +499,10 @@ dist-mutter:
- meson . build --werror --prefix /usr
-Dbuildtype=debugoptimized
- glib-compile-schemas $GSETTINGS_SCHEMA_DIR
- dbus-run-session -- xvfb-run -a -s "$XVFB_SERVER_ARGS"
./.gitlab-ci/run-meson.sh dist -C build
- xvfb-run -a -s "$XVFB_SERVER_ARGS"
./src/tests/meta-dbus-runner.py
--launch=wireplumber
meson dist -C build
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
changes:

View File

@ -1,8 +0,0 @@
#!/usr/bin/bash
set -e
wireplumber &
sleep 1
meson "$@"