#include "Test/CTest.h" #include "Feature/SemanticTokens.h" namespace clice::testing { namespace { struct SemanticTokens : ::testing::Test { std::optional tester; index::Shared> result; struct InputCase { std::uint32_t offset; SymbolKind kind; std::source_location current; }; std::vector cases; void run(llvm::StringRef code) { tester.emplace("main.cpp", code); tester->run(); auto& info = tester->info; result = feature::semanticTokens(*info); } void EXPECT_TOKEN(llvm::StringRef pos, SymbolKind kind, std::source_location current = std::source_location::current()) {} void test() {} }; TEST_F(SemanticTokens, Include) { run("#include "); auto& tokens = result[tester->info->getInterestedFile()]; print("Tokens: {}\n", dump(tokens)); } } // namespace } // namespace clice::testing