mirror of
https://github.com/DeeJanuz/frametop.git
synced 2026-10-06 04:04:09 +02:00
Add independent KDE mouse input and controller fallback
This commit is contained in:
1 parent
7816633353
commit
8afd42798f
22 files changed
+1440
-18
No files matched your search
Executable
+27
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env bash
|
||||
# Offline native input tests; --headless also starts an isolated test desktop.
|
||||
set -euo pipefail
|
||||
root=$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)
|
||||
cd "$root"
|
||||
[[ $# == 0 || ($# == 1 && $1 == --headless) ]] || { echo 'Usage: scripts/test-desktop-input.sh [--headless]' >&2; exit 2; }
|
||||
python3 -m unittest discover -s input -p 'test_desktop_mouse.py'
|
||||
"$root/scripts/frame.sh" -C screens 'set -e; mkdir -p build
|
||||
gcc -std=c11 -Wall -Wextra -Werror tests/desktop-mouse-test.c -lm -o build/desktop-mouse-test
|
||||
build/desktop-mouse-test
|
||||
gcc -std=c11 -Wall -Wextra -Werror tests/controller-fallback-test.c -o build/controller-fallback-test
|
||||
build/controller-fallback-test
|
||||
gcc -std=c11 -Wall -Wextra -Werror $(pkg-config --cflags libdrm) tests/desktop-cursor-test.c -o build/desktop-cursor-test
|
||||
build/desktop-cursor-test
|
||||
gcc -std=c11 -Wall -Wextra -Werror tests/cursor-cache-test.c $(pkg-config --cflags --libs wlroots-0.20 wayland-server wayland-client libdrm pixman-1) -o build/cursor-cache-test
|
||||
build/cursor-cache-test'
|
||||
if [[ ${1:-} == --headless ]]; then
|
||||
# Reuses upstream's throwaway @ft_screens_test fixture, never the live desktop.
|
||||
if pgrep -f '[f]t-screens.*--control ft_screens_test' >/dev/null; then
|
||||
echo 'Test desktop already running; stop it yourself before this test.' >&2
|
||||
exit 1
|
||||
fi
|
||||
"$root/screens/build.sh"
|
||||
trap '"$root/screens/test/headless.sh" stop' EXIT
|
||||
"$root/screens/test/headless.sh" start 2 3
|
||||
python3 "$root/screens/tests/desktop-input-integration.py"
|
||||
fi
|
||||
Reference in new issue
Block a user