Add quarantined Xorg destination-key ownership and cleanup

This commit is contained in:
ak47 committed 2026-11-05 21:56:14 -05:00
1 parent 792cac5d0b
commit cd9ae05bbe
10 files changed
+988 -29

No files matched your search

+28
View File
@@ -0,0 +1,28 @@
#!/usr/bin/env python3
# Copyright (c) 2026 Storm Dragon
# Authors: Storm Dragon, Angus Kola
# SPDX-License-Identifier: GPL-3.0-or-later
"""Exercise quarantined destination-key ownership on a private Xvfb server."""
import os
from pathlib import Path
import shutil
import sys
from native_test_session import run_private_session
def main():
for program in ("xvfb-run", "dbus-run-session", "setxkbmap", "go"):
if shutil.which(program) is None:
raise RuntimeError(f"Required private-test dependency is missing: {program}")
environment = dict(os.environ, CTHULHU_NATIVE_REMOTE_KEYS="1",
GOCACHE="/tmp/cthulhu-cache", GOPROXY="off")
command = ["xvfb-run", "-a", "-s", "-screen 0 1024x768x24", "dbus-run-session", "--",
"go", "test", "-race", "./internal/platform/xorg", "-count=1", "-timeout=60s",
"-run", "^TestNativeRemoteKeyTarget", "-v"]
return run_private_session(command, env=environment,
cwd=Path(__file__).resolve().parents[1], check=True).returncode
if __name__ == "__main__":
sys.exit(main())