test(gtk): live D-Bus/portal comparison against the original Ghostty
Adds scripts/live-dbus-test.sh (`just live-dbus`): each scenario runs the installed Ghostty 1.3.1 and the Rust build on a private dbus-run-session bus inside a private headless weston (the user's session bus is never written to), with Python/Gio mocks for org.freedesktop.Notifications, the GlobalShortcuts/Settings portal and org.freedesktop.systemd1, plus a real xdg-desktop-portal run. Scenarios: single-instance (+detect), +new-window with arguments, notifications, global shortcuts, color-scheme settings, cgroup scope creation, URL opening. tests/live_dbus.rs compares the Rust build against goldens recorded from the original (skips when tools or a fresh production build are missing). Two Rust bugs found and fixed (no upstream deviation): - GlobalShortcuts CreateSession/BindShortcuts payloads used the wrong D-Bus signatures ((v), double-boxed values), which a real portal rejects; signature tests added. - CreateSession was sent twice at startup; the config is now bound only after the D-Bus connection is set, as in Zig. All nine scenarios now behave identically to the original (docs/rewrite/notes/live-dbus.md). Test Plan: - just live-dbus - cargo test --test live_dbus (needs target/vp/production/ghostty)
This commit is contained in:
1 parent
5cb5bbada2
commit
39865d0ae1
25 files changed
+1278
-31
No files matched your search
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
# Enables color-scheme reporting (mode 2031), asks for the current scheme
|
||||
# (CSI ? 996 n) and keeps asking for the background colour (OSC 11).
|
||||
esc=$(printf '\033'); bel=$(printf '\007')
|
||||
stty raw -echo
|
||||
printf '%s[?2031h%s[?996n' "$esc" "$esc"
|
||||
( while :; do printf '%s]11;?%s' "$esc" "$bel"; sleep 0.7; done ) &
|
||||
exec cat -v >>"$OUTF"
|
||||
Reference in new issue
Block a user