CMakeLists.txt for ApprovalTests Configuration
if(NOT TARGET ApprovalTests) set(LIB_NAME ApprovalTests) add_library(${LIB_NAME} INTERFACE) target_include_directories(${LIB_NAME} INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) add_library(${0 码力 | 1 页 | 250.00 B | 5 月前3Quickly Testing Qt Desktop Applications With Approval Tests
–Summary58 Introducing ApprovalTests.cpp.Qt59 Introducing ApprovalTests.cpp.Qt • github.com/approvals/ApprovalTests.cpp.Qt Catch2 ApprovalTests.cpp Qt5 Test Qt5 Widgets ApprovalTests.cpp.Qt60 Introducing Introducing ApprovalTests.cpp.Qt •Goals • Rapidly start testing Qt code – Useful even if you don’t use Approval Tests! • Approval Tests support for Qt types – Easy saving of state in Golden Output files • github.com/approvals/ApprovalTests.cpp.Qt • github.com/approvals/ApprovalTests.cpp.Qt.StarterProject • v.0.0.261 Setting up testsuite main() // Original Code #define CATCH_CONFIG_RUNNER #include0 码力 | 77 页 | 6.96 MB | 5 月前391HeLLoApprovats
cpp ) target_link_libraries(${EXE_NAME} shared_code::shared_code ApprovalTests::ApprovalTests Catch2::Catch2 ) target_compile_definitions(${EXE_NAME} PRIVATE CATCH0 码力 | 1 页 | 406.00 B | 5 月前393LogFites
cpp ) target_link_libraries(${EXE_NAME} shared_code::shared_code ApprovalTests::ApprovalTests Catch2::Catch2 ) target_compile_definitions(${EXE_NAME} PRIVATE CATCH0 码力 | 1 页 | 404.00 B | 5 月前3694SVGFites CMake Configuration
h ) target_link_libraries(${EXE_NAME} shared_code::shared_code ApprovalTests::ApprovalTests Catch2::Catch2 ) target_compile_definitions(${EXE_NAME} PRIVATE CATCH0 码力 | 1 页 | 436.00 B | 5 月前3Gilded Rose
tests/detailed_tests/GildedRoseApprovalsAllSteps.cpp ) target_link_libraries(${EXE_NAME} ApprovalTests::ApprovalTests Catch2::Catch2 ) target_compile_definitions(${EXE_NAME} PRIVATE CATCH0 码力 | 1 页 | 816.00 B | 5 月前3AppovatTestsQt
find_package(Qt5 COMPONENTS Widgets Test REQUIRED) target_link_libraries(${LIB_NAME} INTERFACE ApprovalTests Qt5::Widgets Qt5::Test) endif ()0 码力 | 1 页 | 398.00 B | 5 月前3Catch2
add_library(Catch2::Catch2 ALIAS Catch2) # This one is historical, left over from when ApprovalTests.cpp was first created. # We could encourage users to move away from it. add_library(catch20 码力 | 1 页 | 519.00 B | 5 月前3
共 8 条
- 1