feat(nix): the resize scenario and a pointer on the Platform

Platform.has says whether a platform can do what a scenario needs, and
Platform.pointer is a Pointer (move, down, up, drag) where it has one;
KdePlatform takes the pointer of a session node. scenarios.resize drags the
edge two tiles share by 60 pixels and checks that the tiles that end at the
edge are that much wider, the ones that start after it start that much
later and end where they did, nothing moves up or down, and tiles that do
not touch the edge are where they were. A platform with no pointer skips
it, and says so.

The fake daemon has a pointer that moves an edge. The scenario runs on KDE
at the end of drag-resize: 19 checks pass on KVM. Its first run failed one
check that was the scenario's: both tiles of a BSP column share the dragged
edge, and the check took the second for one that had not moved.
This commit is contained in:
LGUG2Z committed 2026-10-30 12:03:00 -07:00
1 parent e385bace05
commit 37b75f8205
8 files changed
+273 -24

No files matched your search

+11 -11
View File
@@ -154,19 +154,19 @@ the run.
daemon, run `komorebic`, read the `Snapshot`, open a window, ask whether the
daemon put it away (`hidden`), ask the operating system for its frame
(`os_window`, the oracle: the daemon's state is the thing under test), and take
a screenshot. `core/scenarios` has the scenarios written against it: `tiling`,
`focus`, `moving`, `stacks` and `workspaces`, which `core-e2e` runs on KDE and which a suite
of kfw can run unchanged. A method is added with the first scenario that needs
it. `KdePlatform` (`kde_platform.py`) is a `Kde` session as a `Platform`, and
the `core-e2e` suite runs the scenarios through it after its own sections.
a screenshot. Where the platform has a pointer (`has("pointer")`), a scenario moves
it with `pointer.drag`; where it has none, the scenario says so and is skipped.
`core/scenarios` has the scenarios written against it: `tiling`, `focus`, `moving`,
`stacks`, `workspaces` and `resize`. A method is added with the first scenario that
needs it. `KdePlatform` (`kde_platform.py`) is a `Kde` session as a `Platform`.
[Writing a scenario](#writing-a-scenario) says how to add one.
The scenarios run on two platforms. KDE runs all five, in `core-e2e`. A Windows 11
guest under QEMU, which kfw drives from its own tree, has run `tiling` against kfw's
daemon (10 of 10 checks on 2026-10-29, reported by the session that ran it, with this
`core/` copied unchanged); `focus`, `moving`, `stacks` and `workspaces` have not run
there yet. `scripts/sync-e2e-core` keeps kfw's copy of `core/` in step until `core/`
moves there.
The scenarios run on two platforms. KDE runs all six: five at the end of `core-e2e`,
and `resize`, which needs a pointer, at the end of `drag-resize`. A Windows 11 guest
under QEMU, which kfw drives from its own tree, has run `tiling`, `focus`, `moving`,
`stacks` and `workspaces` against kfw's daemon (reported by the session that ran them,
2026-10-29, with this `core/` copied unchanged); `resize` has not run there yet.
`scripts/sync-e2e-core` keeps kfw's copy of `core/` in step until `core/` moves there.
- `Checks` counts checks and fails once, at the end, so that one failure does
not hide the ones after it. `finish()` prints `passed: N failed: M`, and its
error names the checks that failed, which `nix build` shows in the last lines