libglvnd/tests/init_test_env.sh
Brian Nguyen acb5f98231 [tests] Replace SKIP_ENV_INIT with DO_X11_TESTS
Instead of requiring a special environment variable to skip tests
which require a special X11 environment, skip these tests by default
and have users opt-in with the DO_X11_TESTS environment variable.

Signed-off-by: Brian Nguyen <brnguyen@nvidia.com>
2013-09-27 10:25:45 -07:00

21 lines
401 B
Bash
Executable file

#!/bin/bash
echo -n "Initializing test environment... "
if [ -z "$DO_X11_TESTS" ]; then
echo "skipped"
exit 77
fi
echo "(unset DO_X11_TESTS to disable this step)"
X -config "$ABS_TOP_BUILDDIR/tests/xorg.2screens.conf" \
-modulepath "/usr/lib/xorg/modules/,$ABS_TOP_BUILDDIR/src/x11glvnd/.libs" \
-retro -keeptty -noreset \
$DISPLAY &> /dev/null &
echo $! > xorg.pid
sleep 5
exit 0