1 # RUN: clangd -lit-test < %s | FileCheck -strict-whitespace %s
2 {"jsonrpc":"2.0","id":0,"method":"initialize","params":{"processId":123,"rootPath":"clangd","capabilities":{},"trace":"off"}}
4 {"jsonrpc":"2.0","method":"textDocument/didOpen","params":{"textDocument":{"uri":"test:///main.cpp","languageId":"cpp","version":1,"text":"void func() {}"}}}
6 {"jsonrpc":"2.0","id":1,"method":"$/memoryUsage","params":{}}
8 # CHECK-NEXT: "jsonrpc": "2.0",
9 # CHECK-NEXT: "result": {
10 # CHECK-NEXT: "_self": {{[0-9]+}},
11 # CHECK-NEXT: "_total": {{[0-9]+}},
12 # CHECK-NEXT: "clangd_server": {
13 # CHECK-NEXT: "_self": {{[0-9]+}},
14 # CHECK-NEXT: "_total": {{[0-9]+}},
15 # CHECK-NEXT: "dynamic_index": {
16 # CHECK-NEXT: "_self": {{[0-9]+}},
17 # CHECK-NEXT: "_total": {{[0-9]+}},
18 # CHECK-NEXT: "main_file": {
19 # CHECK-NEXT: "_self": {{[0-9]+}},
20 # CHECK-NEXT: "_total": {{[0-9]+}},
21 # CHECK-NEXT: "index": {
22 # CHECK-NEXT: "_self": {{[0-9]+}},
23 # CHECK-NEXT: "_total": {{[0-9]+}}
25 # CHECK-NEXT: "slabs": {
26 # CHECK-NEXT: "_self": {{[0-9]+}},
27 # CHECK-NEXT: "_total": {{[0-9]+}},
28 # CHECK-NEXT: "test:///main.cpp": {
29 # CHECK-NEXT: "_self": {{[0-9]+}},
30 # CHECK-NEXT: "_total": {{[0-9]+}},
31 # CHECK-NEXT: "references": {
32 # CHECK-NEXT: "_self": {{[0-9]+}},
33 # CHECK-NEXT: "_total": {{[0-9]+}}
35 # CHECK-NEXT: "relations": {
36 # CHECK-NEXT: "_self": {{[0-9]+}},
37 # CHECK-NEXT: "_total": {{[0-9]+}}
39 # CHECK-NEXT: "symbols": {
40 # CHECK-NEXT: "_self": {{[0-9]+}},
41 # CHECK-NEXT: "_total": {{[0-9]+}}
46 # CHECK-NEXT: "preamble": {
47 # CHECK-NEXT: "_self": {{[0-9]+}},
48 # CHECK-NEXT: "_total": {{[0-9]+}},
49 # CHECK-NEXT: "index": {
50 # CHECK-NEXT: "_self": {{[0-9]+}},
51 # CHECK-NEXT: "_total": {{[0-9]+}}
53 # CHECK-NEXT: "slabs": {
54 # CHECK-NEXT: "_self": {{[0-9]+}},
55 # CHECK-NEXT: "_total": {{[0-9]+}}
59 # CHECK-NEXT: "tuscheduler": {
60 # CHECK-NEXT: "{{.*}}main.cpp": {
61 # CHECK-NEXT: "_self": {{[0-9]+}},
62 # CHECK-NEXT: "_total": {{[0-9]+}},
63 # CHECK-NEXT: "ast": {
64 # CHECK-NEXT: "_self": {{[0-9]+}},
65 # CHECK-NEXT: "_total": {{[0-9]+}}
67 # CHECK-NEXT: "preamble": {
68 # CHECK-NEXT: "_self": {{[0-9]+}},
69 # CHECK-NEXT: "_total": {{[0-9]+}}
72 # CHECK-NEXT: "_self": {{[0-9]+}},
73 # CHECK-NEXT: "_total": {{[0-9]+}},
74 # CHECK-NEXT: "header_includer_cache": {
75 # CHECK-NEXT: "_self": {{[0-9]+}},
76 # CHECK-NEXT: "_total": {{[0-9]+}}
82 {"jsonrpc":"2.0","id":3,"method":"shutdown"}
84 {"jsonrpc":"2.0","method":"exit"}