mirror of
https://github.com/emilk/egui.git
synced 2026-09-01 06:10:06 -04:00
Add Harness::debug_open_snapshot helper (#7590)
Adds a helper to quickly see whats going on in a kittest test. Not all test have snapshots, but when debugging tests it might still be useful to see whats actually going on, so this adds a helper fn that renders a snapshot image to a temporary file and opens it with the default image viewer: https://github.com/user-attachments/assets/08785850-0a12-4572-b9b5-cea36951081c
This commit is contained in:
@@ -33,7 +33,7 @@ wgpu = [
|
||||
]
|
||||
|
||||
## Adds a dify-based image snapshot utility.
|
||||
snapshot = ["dep:dify", "dep:image", "image/png"]
|
||||
snapshot = ["dep:dify", "dep:image", "dep:open", "dep:tempfile", "image/png"]
|
||||
|
||||
## Allows testing eframe::App
|
||||
eframe = ["dep:eframe", "eframe/accesskit"]
|
||||
@@ -61,6 +61,8 @@ wgpu = { workspace = true, features = [
|
||||
|
||||
# snapshot dependencies
|
||||
dify = { workspace = true, optional = true }
|
||||
open = { workspace = true, optional = true }
|
||||
tempfile = { workspace = true, optional = true }
|
||||
|
||||
# Enable this when generating docs.
|
||||
document-features = { workspace = true, optional = true }
|
||||
|
||||
Reference in New Issue
Block a user