Skip to content

Commit d50a431

Browse files
committedOct 11, 2018
[python] [tests] Fix calling tests on Windows
Fix passing arguments to the Python test command to use 'env' builtin CMake command, in order to fix compatibility with Windows. Differential Revision: https://reviews.llvm.org/D53151 llvm-svn: 344288
1 parent f04bed8 commit d50a431

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

Diff for: ‎clang/bindings/python/tests/CMakeLists.txt

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
# Test target to run Python test suite from main build.
22

33
add_custom_target(check-clang-python
4-
COMMAND CLANG_LIBRARY_PATH=$<TARGET_FILE_DIR:libclang> ${PYTHON_EXECUTABLE} -m unittest discover
4+
COMMAND ${CMAKE_COMMAND} -E env
5+
CLANG_LIBRARY_PATH=$<TARGET_FILE_DIR:libclang>
6+
${PYTHON_EXECUTABLE} -m unittest discover
57
DEPENDS libclang
68
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/..)
79

0 commit comments

Comments
 (0)
Please sign in to comment.