ci: prove the lavapipe GPU path draws (FIELDCRAFT_REQUIRE_GPU=1)

The drawing tests skipped silently without an adapter. Under
FIELDCRAFT_REQUIRE_GPU=1 they fail instead, and the snapshot and MCP
screenshot tests require a GPU renderer. CI runs them with
FIELDCRAFT_GPU=software on lavapipe.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UhhZMBTviDQxZvwnyP89fo
This commit is contained in:
jyvikoandClaude Opus 5.5 authored and Irakli Kourtis committed 2026-10-16 07:52:10 -04:00
1 parent b905f1bc89
commit c6bc4d2ba0
5 files changed
+24 -5

No files matched your search

+3
View File
@@ -222,6 +222,9 @@ fn screenshot_takes_a_camera_orientation() {
assert_eq!(info["view"], json!({"yaw": 30.0, "pitch": 90.0, "distance": 1e9, "target": {"center_of": "mass"}}), "{info}");
// The reply names what drew it: the viewport's pipeline on a GPU, or the CPU rasterizer.
assert!(matches!(info["renderer"]["kind"].as_str(), Some("hardware" | "software" | "cpu")), "{info}");
if fieldcraft_gpu::select::gpu_required() {
assert!(matches!(info["renderer"]["kind"].as_str(), Some("hardware" | "software")), "FIELDCRAFT_REQUIRE_GPU=1: {info}");
}
let (again, _) = picture(&mut s, json!({"width": 64, "height": 48}));
assert_eq!(again, turned);
// Aimed at a point, the camera looks at it; a section cuts the mesh.