2020-07-31 00:23:15 +02:00
|
|
|
#!/bin/sh
|
|
|
|
|
2020-08-01 02:47:45 +02:00
|
|
|
# Devices that exist on sr.ht
|
|
|
|
if [ -e "/dev/input/event0" ]
|
|
|
|
then
|
|
|
|
file="/dev/input/event0"
|
|
|
|
elif [ -e "/dev/dri/card0" ]
|
|
|
|
then
|
|
|
|
file="/dev/dri/card0"
|
|
|
|
else
|
|
|
|
echo "No useful device file found"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2021-08-06 00:46:49 +02:00
|
|
|
export SEATD_LOGLEVEL=debug
|
2020-07-31 00:23:15 +02:00
|
|
|
#
|
|
|
|
# Run simpletest a few times
|
|
|
|
#
|
|
|
|
cnt=0
|
2021-03-16 13:33:20 +01:00
|
|
|
while [ "$cnt" -lt 2 ]
|
2020-07-31 00:23:15 +02:00
|
|
|
do
|
2021-03-16 13:33:35 +01:00
|
|
|
echo "Simpletest run $((cnt+1))"
|
2021-09-15 23:30:53 +02:00
|
|
|
if ! sudo -E ./build/seatd-launch ./build/simpletest $file
|
2020-07-31 00:23:15 +02:00
|
|
|
then
|
|
|
|
echo "Simpletest failed"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
cnt=$((cnt+1))
|
|
|
|
done
|
|
|
|
|
2020-08-01 16:22:45 +02:00
|
|
|
echo "smoketest-seatd completed"
|