brintos

brintos / llvm-project-archived public Read only

0
0
Text · 5.0 KiB · 2b1b6e0 Raw
203 lines · plain
1set(LLVM_LINK_COMPONENTS2  support3  AllTargetsInfos4  FrontendOpenMP5  TargetParser6  )7 8if(CLANG_BUILT_STANDALONE)9  # LLVMTestingSupport and LLVMTestingAnnotations are needed for clangd tests.10  if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations11      AND NOT TARGET LLVMTestingAnnotations)12    add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Annotations13      lib/Testing/Annotations)14  endif()15  if (EXISTS ${LLVM_MAIN_SRC_DIR}/lib/Testing/Support16      AND NOT TARGET LLVMTestingSupport)17    add_subdirectory(${LLVM_MAIN_SRC_DIR}/lib/Testing/Support18      lib/Testing/Support)19  endif()20endif()21 22if (CLANGD_ENABLE_REMOTE)23  include_directories(${CMAKE_CURRENT_BINARY_DIR}/../index/remote)24  add_definitions(-DGOOGLE_PROTOBUF_NO_RTTI=1)25  set(REMOTE_TEST_SOURCES remote/MarshallingTests.cpp)26endif()27 28include(${CMAKE_CURRENT_SOURCE_DIR}/../quality/CompletionModel.cmake)29gen_decision_forest(${CMAKE_CURRENT_SOURCE_DIR}/decision_forest_model DecisionForestRuntimeTest ::ns1::ns2::test::Example)30 31add_custom_target(ClangdUnitTests)32set_target_properties(ClangdUnitTests PROPERTIES FOLDER "Clang Tools Extra/Tests")33add_unittest(ClangdUnitTests ClangdTests34  Annotations.cpp35  ASTTests.cpp36  ASTSignalsTests.cpp37  BackgroundIndexTests.cpp38  CallHierarchyTests.cpp39  CanonicalIncludesTests.cpp40  ClangdTests.cpp41  ClangdLSPServerTests.cpp42  CodeCompleteTests.cpp43  CodeCompletionStringsTests.cpp44  CollectMacrosTests.cpp45  CompileCommandsTests.cpp46  CompilerTests.cpp47  ConfigCompileTests.cpp48  ConfigProviderTests.cpp49  ConfigYAMLTests.cpp50  DecisionForestTests.cpp51  DexTests.cpp52  DiagnosticsTests.cpp53  DraftStoreTests.cpp54  DumpASTTests.cpp55  ExpectedTypeTest.cpp56  FeatureModulesTests.cpp57  FeatureModulesRegistryTests.cpp58  FileDistanceTests.cpp59  FileIndexTests.cpp60  FindSymbolsTests.cpp61  FindTargetTests.cpp62  FormatTests.cpp63  FSTests.cpp64  FuzzyMatchTests.cpp65  GlobalCompilationDatabaseTests.cpp66  HeadersTests.cpp67  HeaderSourceSwitchTests.cpp68  HoverTests.cpp69  IncludeCleanerTests.cpp70  IndexActionTests.cpp71  IndexTests.cpp72  InlayHintTests.cpp73  InsertionPointTests.cpp74  JSONTransportTests.cpp75  LoggerTests.cpp76  LSPBinderTests.cpp77  LSPClient.cpp78  PrerequisiteModulesTest.cpp79  ModulesTests.cpp80  ParsedASTTests.cpp81  PathMappingTests.cpp82  PreambleTests.cpp83  PrintASTTests.cpp84  ProjectAwareIndexTests.cpp85  QualityTests.cpp86  RIFFTests.cpp87  RenameTests.cpp88  ReplayPeambleTests.cpp89  SelectionTests.cpp90  SemanticHighlightingTests.cpp91  SemanticSelectionTests.cpp92  SerializationTests.cpp93  SourceCodeTests.cpp94  StdLibTests.cpp95  SymbolCollectorTests.cpp96  SymbolDocumentationTests.cpp97  SymbolInfoTests.cpp98  SyncAPI.cpp99  TUSchedulerTests.cpp100  TestFS.cpp101  TestIndex.cpp102  TestTU.cpp103  TestWorkspace.cpp104  ThreadCrashReporterTests.cpp105  TidyProviderTests.cpp106  TypeHierarchyTests.cpp107  URITests.cpp108  XRefsTests.cpp109  ${CMAKE_CURRENT_BINARY_DIR}/DecisionForestRuntimeTest.cpp110 111  support/CancellationTests.cpp112  support/ContextTests.cpp113  support/FileCacheTests.cpp114  support/FunctionTests.cpp115  support/MarkupTests.cpp116  support/MemoryTreeTests.cpp117  support/PathTests.cpp118  support/TestTracer.cpp119  support/ThreadingTests.cpp120  support/TraceTests.cpp121 122  tweaks/AddUsingTests.cpp123  tweaks/AnnotateHighlightingsTests.cpp124  tweaks/DefineInlineTests.cpp125  tweaks/DefineOutlineTests.cpp126  tweaks/DumpASTTests.cpp127  tweaks/DumpRecordLayoutTests.cpp128  tweaks/DumpSymbolTests.cpp129  tweaks/ExpandDeducedTypeTests.cpp130  tweaks/ExpandMacroTests.cpp131  tweaks/ExtractFunctionTests.cpp132  tweaks/ExtractVariableTests.cpp133  tweaks/MemberwiseConstructorTests.cpp134  tweaks/ObjCLocalizeStringLiteralTests.cpp135  tweaks/ObjCMemberwiseInitializerTests.cpp136  tweaks/OverridePureVirtualsTests.cpp137  tweaks/PopulateSwitchTests.cpp138  tweaks/RawStringLiteralTests.cpp139  tweaks/RemoveUsingNamespaceTests.cpp140  tweaks/ScopifyEnumTests.cpp141  tweaks/ShowSelectionTreeTests.cpp142  tweaks/SpecialMembersTests.cpp143  tweaks/SwapBinaryOperandsTests.cpp144  tweaks/SwapIfBranchesTests.cpp145  tweaks/TweakTesting.cpp146  tweaks/TweakTests.cpp147 148  ${REMOTE_TEST_SOURCES}149 150  $<TARGET_OBJECTS:obj.clangDaemonTweaks>151  )152 153# Include generated ComletionModel headers.154target_include_directories(ClangdTests PUBLIC155  $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}>156)157 158clang_target_link_libraries(ClangdTests159  PRIVATE160  clangAST161  clangASTMatchers162  clangBasic163  clangFormat164  clangFrontend165  clangIndex166  clangLex167  clangSema168  clangSerialization169  clangTooling170  clangToolingCore171  clangToolingInclusions172  clangToolingInclusionsStdlib173  clangToolingRefactoring174  clangToolingSyntax175  )176target_link_libraries(ClangdTests177  PRIVATE178  LLVMTestingAnnotations179  LLVMTestingSupport180 181  clangDaemon182  clangIncludeCleaner183  clangTesting184  clangTidy185  clangTidyUtils186  clangdSupport187  )188 189if (CLANGD_ENABLE_REMOTE)190  target_link_libraries(ClangdTests191    PRIVATE192    clangdRemoteMarshalling193    clangdRemoteIndexProto)194endif()195 196if (CLANGD_BUILD_XPC)197  add_subdirectory(xpc)198endif ()199 200configure_lit_site_cfg(201  ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.py.in202  ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg.py)203