meson: Add Xvfb and Xephyr-glamor testing.

The Xvfb tests are passing and Xephyr-glamor is failing for me, but it
fails identically on autotools.  It's disabled on Travis for now
because the >10 minutes of silence during testing times out the entire
build.

v2: Fix the disable on travis.

Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
Eric Anholt 2017-09-18 17:34:29 -07:00 committed by Adam Jackson
parent a09743c930
commit a8eeb332cc
4 changed files with 39 additions and 0 deletions

View File

@ -426,3 +426,4 @@ libxserver = [
libxserver += libxserver_dri3 libxserver += libxserver_dri3
subdir('hw') subdir('hw')
subdir('test')

24
test/meson.build Normal file
View File

@ -0,0 +1,24 @@
simple_xinit = executable(
'simple-xinit',
'simple-xinit.c',
include_directories: inc,
)
piglit_env = environment()
piglit_env.set('XSERVER_DIR', meson.source_root())
piglit_env.set('XSERVER_BUILDDIR', meson.build_root())
if get_option('xvfb')
test('xvfb-piglit', find_program('scripts/xvfb-piglit.sh'),
env: piglit_env,
timeout: 1200,
)
if get_option('xephyr') and build_glamor
test('xephyr-glamor',
find_program('scripts/xephyr-glamor-piglit.sh'),
env: piglit_env,
timeout: 1200,
)
endif
endif

View File

@ -1,3 +1,10 @@
#!/bin/sh
# this times out on Travis, because the tests take too long.
if test "x$TRAVIS_BUILD_DIR" != "x"; then
exit 77
fi
# Start a Xephyr server using glamor. Since the test environment is # Start a Xephyr server using glamor. Since the test environment is
# headless, we start an Xvfb first to host the Xephyr. # headless, we start an Xvfb first to host the Xephyr.
export PIGLIT_RESULTS_DIR=$XSERVER_BUILDDIR/test/piglit-results/xephyr-glamor export PIGLIT_RESULTS_DIR=$XSERVER_BUILDDIR/test/piglit-results/xephyr-glamor

View File

@ -1,3 +1,10 @@
#!/bin/sh
# this times out on Travis, because the tests take too long.
if test "x$TRAVIS_BUILD_DIR" != "x"; then
exit 77
fi
export SERVER_COMMAND="$XSERVER_BUILDDIR/hw/vfb/Xvfb \ export SERVER_COMMAND="$XSERVER_BUILDDIR/hw/vfb/Xvfb \
-noreset \ -noreset \
-screen scrn 1280x1024x24" -screen scrn 1280x1024x24"