brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.4 KiB · eef8f52 Raw
52 lines · plain
1set(CLANGD_TEST_DEPS2  clangd3  ClangdTests4  clangd-indexer5  split-file6  )7 8if (LLVM_INCLUDE_BENCHMARKS)9  list(APPEND CLANGD_TEST_DEPS IndexBenchmark)10endif()11 12if(CLANGD_BUILD_XPC)13  list(APPEND CLANGD_TEST_DEPS clangd-xpc-test-client)14  list(APPEND CLANGD_TEST_DEPS ClangdXpcUnitTests)15endif()16 17if(CLANGD_BUILD_DEXP)18  # No tests for it, but we should still make sure they build.19  list(APPEND CLANGD_TEST_DEPS dexp)20endif()21 22if(CLANGD_ENABLE_REMOTE)23  list(APPEND CLANGD_TEST_DEPS clangd-index-server clangd-index-server-monitor)24endif()25 26foreach(dep FileCheck count not llvm-config)27  if(TARGET ${dep})28    list(APPEND CLANGD_TEST_DEPS ${dep})29  endif()30endforeach()31 32configure_lit_site_cfg(33  ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.py.in34  ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg.py35  MAIN_CONFIG36  ${CMAKE_CURRENT_SOURCE_DIR}/lit.cfg.py37  )38 39# Copy an empty compile_flags.txt to make sure tests don't pick up arbitrary40# commands from parents.41file(42  TOUCH43  ${CMAKE_CURRENT_BINARY_DIR}/compile_flags.txt44)45 46add_lit_testsuite(check-clangd "Running the Clangd regression tests"47  # clangd doesn't put unittest configs in test/unit like every other project.48  # Because of that, this needs to pass two folders here, while every other49  # project only needs to pass CMAKE_CURRENT_BINARY_DIR.50  ${CMAKE_CURRENT_BINARY_DIR}/../unittests;${CMAKE_CURRENT_BINARY_DIR}51  DEPENDS ${CLANGD_TEST_DEPS})52