mirror of
https://github.com/yshui/picom.git
synced 2025-02-10 15:45:57 -05:00
ci: run tests with all backends
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
parent
5e0c4d42f8
commit
2e6b6d1651
1 changed files with 20 additions and 9 deletions
|
@ -1,4 +1,4 @@
|
|||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
set -xe
|
||||
if [ -z $DISPLAY ]; then
|
||||
exec xvfb-run -s "+extension composite" -a $0 $1 $2 $3
|
||||
|
@ -6,14 +6,25 @@ fi
|
|||
|
||||
echo "Running test $2"
|
||||
|
||||
# TODO keep the log file, and parse it to see if test is successful
|
||||
($1 --dbus --backend dummy --log-level=debug --log-file=$PWD/log --config=$2) &
|
||||
main_pid=$!
|
||||
$3
|
||||
picom_exe=$1
|
||||
config=$2
|
||||
test_script=$3
|
||||
|
||||
kill -INT $main_pid || true
|
||||
cat log
|
||||
rm log
|
||||
wait $main_pid
|
||||
function test_with_backend() {
|
||||
backend=$1
|
||||
# TODO keep the log file, and parse it to see if test is successful
|
||||
($picom_exe --dbus --backend $backend --log-level=debug --log-file=$PWD/log --config=$config) &
|
||||
main_pid=$!
|
||||
$test_script
|
||||
|
||||
kill -INT $main_pid || true
|
||||
cat log
|
||||
rm log
|
||||
wait $main_pid
|
||||
}
|
||||
|
||||
test_with_backend dummy
|
||||
test_with_backend xrender
|
||||
test_with_backend glx
|
||||
# test_with_backend egl
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue