summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--meson.build1
-rw-r--r--test/meson.build24
-rwxr-xr-xtest/scripts/xephyr-glamor-piglit.sh7
-rwxr-xr-xtest/scripts/xvfb-piglit.sh7
4 files changed, 39 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 3efec0def..ea2a01520 100644
--- a/meson.build
+++ b/meson.build
@@ -426,3 +426,4 @@ libxserver = [
libxserver += libxserver_dri3
subdir('hw')
+subdir('test')
diff --git a/test/meson.build b/test/meson.build
new file mode 100644
index 000000000..b71d7e249
--- /dev/null
+++ b/test/meson.build
@@ -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
diff --git a/test/scripts/xephyr-glamor-piglit.sh b/test/scripts/xephyr-glamor-piglit.sh
index 51d42c313..c16fdc4f3 100755
--- a/test/scripts/xephyr-glamor-piglit.sh
+++ b/test/scripts/xephyr-glamor-piglit.sh
@@ -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
# headless, we start an Xvfb first to host the Xephyr.
export PIGLIT_RESULTS_DIR=$XSERVER_BUILDDIR/test/piglit-results/xephyr-glamor
diff --git a/test/scripts/xvfb-piglit.sh b/test/scripts/xvfb-piglit.sh
index 763599ef4..ae9f4662e 100755
--- a/test/scripts/xvfb-piglit.sh
+++ b/test/scripts/xvfb-piglit.sh
@@ -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 \
-noreset \
-screen scrn 1280x1024x24"