GUI Milestone 7

This commit is contained in:
Joey Yakimowich-Payne 2026-01-30 06:44:18 -07:00
commit 7ec61e5759
3 changed files with 513 additions and 29 deletions

View file

@ -88,4 +88,35 @@ if(WARPPIPE_BUILD_GUI)
Qt6::Widgets
QtNodes
)
if(WARPPIPE_BUILD_TESTS)
add_executable(warppipe-gui-tests
tests/gui/warppipe_gui_tests.cpp
gui/WarpGraphModel.cpp
)
target_compile_definitions(warppipe-gui-tests PRIVATE WARPPIPE_TESTING)
target_link_libraries(warppipe-gui-tests PRIVATE
warppipe
Qt6::Core
Qt6::Widgets
QtNodes
Catch2::Catch2WithMain
)
add_test(NAME warppipe_gui_tests COMMAND warppipe-gui-tests)
option(WARPPIPE_GUI_VISUAL_TESTS "Enable screenshot-based visual tests" OFF)
if(WARPPIPE_GUI_VISUAL_TESTS)
add_test(NAME gui_screenshot_smoke
COMMAND ${CMAKE_COMMAND} -E env QT_QPA_PLATFORM=offscreen
$<TARGET_FILE:warppipe-gui> --screenshot ${CMAKE_BINARY_DIR}/test_screenshot.png
)
set_tests_properties(gui_screenshot_smoke PROPERTIES
LABELS "visual"
TIMEOUT 10
)
endif()
endif()
endif()