Files
CoopAllTheThings/tests/focus_spoof_test.cpp
BlackMark e096a9f2e2 Add focus_spoof_test (and close the dedicated-hook-tests item)
focus_spoof_test plays game + host: it creates a top-level window (which
find_main_window picks up), installs the spoof, and checks that
GetForegroundWindow / GetActiveWindow / GetFocus now report that window, that the
status flag flips on install and off on removal, and that a ClipCursor request is
swallowed while cursor release is the default. Skips if the window can't be
enumerated.

With this and d3d9_hook_test, the dedicated-hook-tests item is done. vk_hook's
present path is intentionally not given a separate in-process test: it's exercised
end to end by mock_game_test's vk-inject path ("hook captured Vulkan present
calls"), and the off-thread VkCapture it drives has vk_capture_perf_test -- a
standalone in-process Vulkan swapchain harness would just duplicate that at high
cost.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-24 02:12:42 +02:00

3.8 KiB