Skip to content

Commit cd1824f

Browse files
committed
Add path of umf.dll to DLL_PATH_LIST for tests on Windows
Signed-off-by: Lukasz Dorau <[email protected]>
1 parent 0358201 commit cd1824f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

test/CMakeLists.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,17 @@ function(add_umf_test)
145145
set_tests_properties(${TEST_NAME} PROPERTIES LABELS "umf")
146146

147147
if(WINDOWS)
148+
# add PATH to DLL on Windows
149+
if(CMAKE_GENERATOR STREQUAL "Ninja")
150+
set(DLL_PATH_LIST
151+
"${DLL_PATH_LIST};PATH=path_list_append:${CMAKE_BINARY_DIR}/bin"
152+
)
153+
else()
154+
set(DLL_PATH_LIST
155+
"${DLL_PATH_LIST};PATH=path_list_append:${CMAKE_BINARY_DIR}/bin/$<CONFIG>/"
156+
)
157+
endif()
158+
148159
# append PATH to DLLs
149160
set_property(TEST ${TEST_NAME} PROPERTY ENVIRONMENT_MODIFICATION
150161
"${DLL_PATH_LIST}")

0 commit comments

Comments
 (0)