Plan new document creation in app core

This commit is contained in:
2026-06-02 23:14:35 +02:00
parent fd1772a417
commit 853307697a
10 changed files with 284 additions and 21 deletions

View File

@@ -411,6 +411,26 @@ if(TARGET pano_cli)
LABELS "app;integration;desktop-fast"
PASS_REGULAR_EXPRESSION "\"command\":\"plan-document-file\".*\"path\":\"D:/Paint/demo.ppi\".*\"exists\":true.*\"decision\":\"prompt-overwrite\"")
add_test(NAME pano_cli_plan_new_document_smoke
COMMAND pano_cli plan-new-document --work-dir D:/Paint --name demo --resolution-index 3)
set_tests_properties(pano_cli_plan_new_document_smoke PROPERTIES
LABELS "app;integration;desktop-fast"
PASS_REGULAR_EXPRESSION "\"command\":\"plan-new-document\".*\"path\":\"D:/Paint/demo.ppi\".*\"exists\":false.*\"resolution\":2048.*\"decision\":\"save-now\"")
add_test(NAME pano_cli_plan_new_document_overwrite_smoke
COMMAND pano_cli plan-new-document --work-dir D:/Paint --name demo --resolution-index 1 --target-exists)
set_tests_properties(pano_cli_plan_new_document_overwrite_smoke PROPERTIES
LABELS "app;integration;desktop-fast"
PASS_REGULAR_EXPRESSION "\"command\":\"plan-new-document\".*\"path\":\"D:/Paint/demo.ppi\".*\"exists\":true.*\"resolution\":1024.*\"decision\":\"prompt-overwrite\"")
add_test(NAME pano_cli_plan_new_document_rejects_invalid_resolution
COMMAND "${CMAKE_COMMAND}"
-DPANO_CLI=$<TARGET_FILE:pano_cli>
"-DEXPECTED_OUTPUT=document resolution index is out of range"
-P "${CMAKE_CURRENT_SOURCE_DIR}/cmake/expect_pano_cli_plan_new_document_failure.cmake")
set_tests_properties(pano_cli_plan_new_document_rejects_invalid_resolution PROPERTIES
LABELS "app;integration;desktop-fast;fuzz")
add_test(NAME pano_cli_plan_document_version_first_smoke
COMMAND pano_cli plan-document-version --directory D:/Paint --doc-name demo)
set_tests_properties(pano_cli_plan_document_version_first_smoke PROPERTIES