forked from OSchip/llvm-project
[clangd] Don't rely on builtin headers for document-link.test.
This test seems to be failing at HEAD. Reviewed By: kadircet, sammccall Differential Revision: https://reviews.llvm.org/D95670
This commit is contained in:
parent
313a36130f
commit
78c22fbce9
|
@ -1,9 +1,10 @@
|
|||
# for %resource_dir: REQUIRES: clang
|
||||
# %resource_dir actually points at builtin_include_dir, go up one directory.
|
||||
# RUN: clangd -lit-test -resource-dir=%resource_dir/.. < %s | FileCheck -strict-whitespace %s
|
||||
# Create a fake resource_dir so that the test can find the headers.
|
||||
# RUN: rm -rf %/t
|
||||
# RUN: mkdir -p %t/include/ && touch %t/include/foo.h
|
||||
# RUN: clangd -lit-test -resource-dir=%t < %s | FileCheck -strict-whitespace %s
|
||||
{"jsonrpc":"2.0","id":0,"method":"initialize","params":{"processId":123,"rootPath":"clangd","capabilities":{},"trace":"off"}}
|
||||
---
|
||||
{"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"uri":"test:///main.cpp","languageId":"cpp","version":1,"text":"#include <stdint.h>\n#include <stddef.h>"}}}
|
||||
{"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"uri":"test:///main.cpp","languageId":"cpp","version":1,"text":"#include <foo.h>"}}}
|
||||
---
|
||||
{"jsonrpc":"2.0","id":2,"method":"textDocument/documentLink","params":{"textDocument":{"uri":"test:///main.cpp"}}}
|
||||
# CHECK: "id": 2,
|
||||
|
@ -12,7 +13,7 @@
|
|||
# CHECK-NEXT: {
|
||||
# CHECK-NEXT: "range": {
|
||||
# CHECK-NEXT: "end": {
|
||||
# CHECK-NEXT: "character": 19,
|
||||
# CHECK-NEXT: "character": 16,
|
||||
# CHECK-NEXT: "line": 0
|
||||
# CHECK-NEXT: },
|
||||
# CHECK-NEXT: "start": {
|
||||
|
@ -20,20 +21,7 @@
|
|||
# CHECK-NEXT: "line": 0
|
||||
# CHECK-NEXT: }
|
||||
# CHECK-NEXT: },
|
||||
# CHECK-NEXT: "target": "file://{{.*}}/stdint.h"
|
||||
# CHECK-NEXT: },
|
||||
# CHECK-NEXT: {
|
||||
# CHECK-NEXT: "range": {
|
||||
# CHECK-NEXT: "end": {
|
||||
# CHECK-NEXT: "character": 19,
|
||||
# CHECK-NEXT: "line": 1
|
||||
# CHECK-NEXT: },
|
||||
# CHECK-NEXT: "start": {
|
||||
# CHECK-NEXT: "character": 9,
|
||||
# CHECK-NEXT: "line": 1
|
||||
# CHECK-NEXT: }
|
||||
# CHECK-NEXT: },
|
||||
# CHECK-NEXT: "target": "file://{{.*}}/stddef.h"
|
||||
# CHECK-NEXT: "target": "file://{{.*}}/foo.h"
|
||||
# CHECK-NEXT: }
|
||||
# CHECK-NEXT: ]
|
||||
# CHECK-NEXT:}
|
||||
|
|
Loading…
Reference in New Issue