Skip to content

Commit

Permalink
testrunner MSVC Debug build stack size increase yfor Formula tests, c…
Browse files Browse the repository at this point in the history
  • Loading branch information
nuoun authored Aug 9, 2024
1 parent 1fd80a8 commit 97767e7
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions src/surge-testrunner/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,25 @@ add_executable(${PROJECT_NAME}
UnitTestsTUN.cpp
UnitTestsVOICE.cpp
main.cpp
)
)

target_link_libraries(${PROJECT_NAME} PRIVATE
surge-lua-src
surge::catch2_v3
surge::surge-common
juce::juce_audio_basics
)
)

target_compile_definitions(${PROJECT_NAME} PUBLIC
JUCE_WEB_BROWSER=0
JUCE_USE_CURL=0
)
JUCE_WEB_BROWSER=0
JUCE_USE_CURL=0
)

# Set stack size to 16MB for MSVC Debug builds only to prevent stack overflow in "Basic Formula Evaluation" Lua tests
if (MSVC AND CMAKE_BUILD_TYPE STREQUAL "Debug")
message(STATUS "Increasing stack size for MSVC Debug build to accommodate Formula Evaluation Lua tests")
set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /STACK:0x1000000")
endif()

message(STATUS "Using CatchDiscoverTests on ${PROJECT_NAME}" )
catch_discover_tests(${PROJECT_NAME} WORKING_DIRECTORY ${SURGE_SOURCE_DIR})
catch_discover_tests(${PROJECT_NAME} WORKING_DIRECTORY ${SURGE_SOURCE_DIR})

0 comments on commit 97767e7

Please sign in to comment.