Commit Graph
1733 Commits
Author SHA1 Message Date
LGUG2Z d4d293fbd8 fix(e2e): run a scenario again when QEMU aborted under it
QEMU has died with SIGABRT while a second display was plugged in (a
hotplug repeat and monitors.at_cursor), which is not a result about kfw.
Its stderr is kept, a dead guest is named as such, and the scenario is
run once more on a fresh guest.
2026-10-30 18:22:44 -07:00
LGUG2Z ea449c2d80 feat(e2e): let the test window rename itself and go fullscreen
--rename-to T --after S gives the window another title S seconds after it
opens, as a program that sets its title late does. The message WM_APP + 2
takes it fullscreen, borderless over its monitor, and back.
2026-10-30 18:22:44 -07:00
LGUG2Z e22d82853c feat(e2e): run kfde's new scenarios on the Windows guest
monitors, layout_flip, title_rule, handover, queries, display_change and
fullscreen, with the extra functions their files have after run
(hotplug.user_move, resize.edge_cases, maximizing.user,
lifecycle_hidden.crash, monocle.focus_behaviour, monitors.at_cursor).
2026-10-30 18:22:44 -07:00
LGUG2Z 320b12b34c feat(e2e): the new Platform members on the Windows guest
spawn takes rename_to and after (the test window renames itself),
temp_path, crash (kills the daemon), fullscreen and user_maximize (the
user's own, by messages the window understands), with tests: a window
that is not there raises, a program name Windows rejects is rejected.
2026-10-30 18:22:44 -07:00
LGUG2Z 81b12ba0b9 feat(e2e): sync the neutral core from kfde c71c8fd0 2026-10-30 18:22:44 -07:00
LGUG2Z 2d830fed8a test(nix): run the e2e tests in nix flake check
The vendored core's tests and those of the runner, which need no guest.
2026-10-30 18:22:44 -07:00
LGUG2Z 09ce64e3e4 test(e2e): test the runner of the Windows guest without a guest
The fix-commit check of the known-failure markers, the scope in the result
file, the step wrapper, the state key and the state that is not JSON.
2026-10-30 18:22:44 -07:00
LGUG2Z 5ef1666053 perf(e2e): key the saved state on the QEMU command line, not guest.py
Any edit to guest.py made a new state (76 to 145 s). The state now follows
the command line of the guest that is saved, with the paths as
placeholders, so an edit to the rest of guest.py does not.
2026-10-30 18:22:44 -07:00
LGUG2Z e440a73666 fix(e2e): a state that is not JSON is an error a wait goes past
komorebic state can print something else while the daemon is busy or in
the middle of a monitor change. The runner crashed on it (a hotplug run
did); now it is a RuntimeError with what was printed, which waits retry.
2026-10-30 18:22:44 -07:00
LGUG2Z 4cef0ce510 feat(e2e): sync the neutral core from kfde 6748528b 2026-10-30 18:22:44 -07:00
LGUG2Z da966bfc78 feat(e2e): drop a known-failure marker once the commit under test has the fix
The runner reads the commit from the binaries' commit file and asks git
whether it contains the fix of the bug a marker is for, so the same runner
tests a branch with the bug and one without it.
2026-10-30 18:22:44 -07:00
LGUG2Z a3468e870c feat(e2e): say which display of the Windows guest can change mode 2026-10-30 18:22:44 -07:00
LGUG2Z f0f369f606 feat(e2e): add probes of display modes and of changing one 2026-10-30 18:22:44 -07:00
LGUG2Z 9c5b71a8c3 feat(e2e): add the display_change extra for the Windows guest
With two windows on the second display, its mode is changed to two others
and back: the daemon's monitor follows, the windows stay inside the work
area and apart, and return to where they were. A draft for a shared
scenario.
2026-10-30 18:22:44 -07:00
LGUG2Z be9e6eb36f feat(e2e): change the mode of a display on the Windows guest
display.ps1 lists the display devices and changes the mode of one (the
logic is in C# because PowerShell cannot pass the structs by reference),
and WindowsPlatform.resize_display uses it. Only the QXL display lists
modes; the first one is the basic adapter, which has one.
2026-10-30 18:22:44 -07:00
LGUG2Z 8d5106f732 feat(e2e): sync the neutral core from kfde c03d61dd 2026-10-30 18:22:44 -07:00
LGUG2Z be4f1707ab perf(nix): build the e2e binaries with a constant commit stamp
COMMIT_HASH is in the derivation of the dependencies too, so every commit
rebuilt everything for nix run .#e2e-windows. The e2e build stamps e2e;
the commit under test is KOMOREBI_E2E_COMMIT.
2026-10-30 18:22:44 -07:00
LGUG2Z 116fadb823 feat(e2e): time the phases of a run
The result file and the log say how long the guest, the upload, the daemon
and the scenario took.
2026-10-30 18:22:44 -07:00
LGUG2Z 994d6565a6 refactor(e2e): run the scenarios of the Windows guest as suite steps
Every scenario goes through run_suite, so its checks are labelled
[shared] and the log says which scenario a check came from. Keyword
arguments go through a small wrapper because a step takes positional
ones.
2026-10-30 18:22:44 -07:00
LGUG2Z 7054d02110 feat(e2e): add what only Windows checks as extras
padding (the border's 7 px), cloaking (and what stop does to it), the
config file watch, the system's window tracking behind focus follows
mouse, and a second display with a window sent to it. Each is run after
the tiling windows as windows_<name>, its checks labelled [windows].
2026-10-30 18:22:44 -07:00
LGUG2Z 2f1df7decd fix(e2e): rewrite_config only writes the file
The daemon watches the configuration file it was started with, so the
extra replace-configuration after each write hid the reload that the
scenario is meant to check.
2026-10-30 18:22:44 -07:00
LGUG2Z 30b73be36e feat(e2e): sync the neutral core from kfde 22a81d0b 2026-10-30 18:22:44 -07:00
LGUG2Z ca4744e77e feat(e2e): sync the neutral core from kfde ff599907 2026-10-30 18:22:44 -07:00
LGUG2Z d990729e14 feat(e2e): record the scope of each check in the result file
A check made inside Checks.scoped("windows") has a scope field in
result.json, next to what it already had.
2026-10-30 18:22:44 -07:00
LGUG2Z 32af5164ef feat(e2e): sync the neutral core from kfde d4f67164 2026-10-30 18:22:44 -07:00
LGUG2Z 97712f7510 feat(e2e): name the exe of a rule with its extension on Windows
kfw matches a rule's id against the exe name of the window, which has the
extension, so exe_id returns program.exe.
2026-10-30 18:22:44 -07:00
LGUG2Z 27ce93fe17 feat(e2e): sync the neutral core from kfde 13edc355 2026-10-30 18:22:44 -07:00
LGUG2Z 206fa1748a feat(e2e): add probes of padding, exe rules and locking
w1_padding.py compares kfw's padding with its frames, w1_rules_exe.py runs
the exe rules with the extension in the id, w1_lock.py moves a window
while the screen is locked.
2026-10-30 18:22:44 -07:00
LGUG2Z 275e6b24ae feat(e2e): run the scenarios kfde added on the Windows guest
focus_follows_mouse, layouts, floating, minimizing, padding, maximizing,
workspace_moves, resize_commands, promoting, flipping, pausing, tiling_off,
lifecycle_hidden, scrolling and locking take the tiling windows; the others
are run as they are.
2026-10-30 18:22:44 -07:00
LGUG2Z d9c12d9fc0 feat(e2e): the Platform methods the new scenarios need on Windows
minimize, spawn with a class or an exe name (a copy of the test window
under that name), rewrite_config (writes the file and has the daemon read
it again), lock and unlock (the lock screen and the account's password
through QMP) and move_window (SetWindowPos, corrected for the invisible
border).
2026-10-30 18:22:44 -07:00
LGUG2Z 62ba64a573 feat(e2e): let the test window take its class from --class
The default stays KomorebiTestWin. A rule that matches by class needs
windows of different classes in the same run.
2026-10-30 18:22:44 -07:00
LGUG2Z ca2bb69587 feat(e2e): sync the neutral core from kfde f07c3eb8
Takes in kfde's revs d2745b80 (layouts, floating), 22e0ed01 (minimizing),
06e16878 (padding), 59777d7d (maximizing), 789e2a51 (workspace_moves),
7420cb58 (resize_commands), b66fe560 (promoting), 6f310858 (flipping),
33697a67 (pausing), d423f99b (tiling_off), aebdf2b0 (lifecycle_hidden),
cdac999a (scrolling), a9e5bd80 (rules_class) and f07c3eb8 (rules_exe,
config_reload, locking).
2026-10-30 18:22:44 -07:00
LGUG2Z a8d0a5096d feat(e2e): add the probes behind the Windows guest's findings
Each w1_*.py prints what it saw: the pointer, a second display, hotplug,
the drag, the placement rule, focus follows mouse and what stop leaves
hidden. W1.md has the results.
2026-10-30 18:22:44 -07:00
LGUG2Z 07ef8e93d6 feat(nix): put the e2e guest tools in the devshell
qemu, swtpm, xorriso, socat, git, python with pillow and pytest, OVMF_FD
and PYTHONPATH, so the build scripts and the runner work from nix develop.
2026-10-30 18:22:44 -07:00
LGUG2Z 5840f36e1c feat(e2e): build the golden image in two layers
build-base.sh does the unattended install (about 18 minutes) and
build-golden.sh puts policies, Defender and the display driver on top of
it in about 2.5 minutes through the guest agent (provision.ps1). A qcow2
chain with a relative backing path keeps the two together.

build-ref.sh builds komorebi and komorebic of any commit, and
KOMOREBI_E2E_BINS makes nix run .#e2e-windows test those binaries.
2026-10-30 18:22:44 -07:00
LGUG2Z 9337042a0f feat(e2e): drive a Windows guest under QEMU with the neutral Platform
guest.py starts QEMU and swtpm on an overlay of the golden image, with
saved-state restore (state.py), qmp.py sends keys and the pointer, agent.py
talks to the guest agent, windows_platform.py implements the Platform
protocol and run.py runs the scenarios, one guest each.
2026-10-30 18:22:44 -07:00
LGUG2Z d2a6d34a6d fix(e2e): log what ends the guest agent's connections
A windowless program has nowhere to print a panic, so the agent
writes panics and ended connections to C:\e2e\agent.log.
2026-10-30 18:22:44 -07:00
LGUG2Z db7d8480ad feat(e2e): sync the neutral core from kfde a563bf9c 2026-10-30 18:22:44 -07:00
LGUG2Z 1874b1fc10 feat(e2e): sync the neutral core from kfde 13270678 2026-10-30 18:22:44 -07:00
LGUG2Z 52f4c96817 feat(e2e): sync the neutral core from kfde 2c7e13dd 2026-10-30 18:22:44 -07:00
LGUG2Z 632b6cc366 feat(e2e): sync the neutral core from kfde 7de53180 2026-10-30 18:22:44 -07:00
LGUG2Z 8a8674ac9b feat(e2e): sync the neutral core from kfde bf5da0e6 2026-10-30 18:22:44 -07:00
LGUG2Z 7c59f3e2c6 feat(nix): run the Windows e2e scenarios with nix run .#e2e-windows
E2E_GOLDEN names the golden image built by build-golden.sh; the komorebi,
komorebic and test window binaries, QEMU, swtpm and an OVMF with TPM support
come from the flake. Also exposes the guest agent and the test window as
packages.
2026-10-30 18:22:44 -07:00
LGUG2Z fc38fbf739 feat(e2e): sync the neutral core from kfde a1024d16 2026-10-30 18:22:44 -07:00
LGUG2Z 8c990e4e1d feat(e2e): sync the neutral core from kfde 06c2b6e2 2026-10-30 18:22:44 -07:00
LGUG2Z e20e02bd12 feat(e2e): sync the neutral core from kfde 7db3f9c5 2026-10-30 18:22:44 -07:00
LGUG2Z 3ae77df287 fix(nix): build the Windows SDK the same on every host
xwin makes case-alias symlinks on a case-sensitive filesystem and none on a
case-insensitive one, so the SDK hash depended on the host. Build with
--disable-symlinks, pin that tree's hash, add the CA bundle xwin needs, and
add the lowercase aliases the linker asks for in a separate derivation.
2026-10-30 18:22:44 -07:00
LGUG2Z 048cf3b951 feat(e2e): sync the neutral core from kfde 79f05a86 2026-10-30 18:22:44 -07:00
LGUG2Z 76918d5a88 feat(e2e): sync the neutral core from kfde 5e7e4ff1
Adds commands.unknown_monitor: a window sent to a monitor that does not
exist must stay managed. From kfde change lkprqpuv.
2026-10-30 18:22:44 -07:00
LGUG2Z d2adcc9c28 feat(e2e): sync the neutral core from kfde 8b86c8ee
The commands sweep plugs in a second display first when the platform has
only one. From kfde change xzwqolrv.
2026-10-30 18:22:44 -07:00