diff options
-rw-r--r-- | clang-tools-extra/unittests/clangd/ClangdUnitTests.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/clang-tools-extra/unittests/clangd/ClangdUnitTests.cpp b/clang-tools-extra/unittests/clangd/ClangdUnitTests.cpp index bb6a18f1c4e..c4171e16b33 100644 --- a/clang-tools-extra/unittests/clangd/ClangdUnitTests.cpp +++ b/clang-tools-extra/unittests/clangd/ClangdUnitTests.cpp @@ -199,7 +199,13 @@ main.cpp:2:3: error: something terrible happened)"); // Transform dianostics and check the results. std::vector<std::pair<clangd::Diagnostic, std::vector<clangd::Fix>>> LSPDiags; toLSPDiags( - D, URIForFile("/path/to/foo/bar/main.cpp"), ClangdDiagnosticOptions(), + D, +#ifdef _WIN32 + URIForFile("c:\\path\\to\\foo\\bar\\main.cpp"), +#else + URIForFile("/path/to/foo/bar/main.cpp"), +#endif + ClangdDiagnosticOptions(), [&](clangd::Diagnostic LSPDiag, ArrayRef<clangd::Fix> Fixes) { LSPDiags.push_back( {std::move(LSPDiag), |