From 45863f47d8b09b618709588107f4b09ee3fb0a88 Mon Sep 17 00:00:00 2001 From: Philippe Gil Date: Thu, 18 Apr 2024 18:16:02 +0200 Subject: [PATCH] fix merge conflict commit: adapt test after GPR2 bump. See eng/shared/anod#300 --- .../others/test.yaml | 3 - .../{others => }/prj.gpr | 0 .../{others => }/test.json | 0 .../import_using_space_string/test.yaml | 1 + .../import_using_space_string/windows/prj.gpr | 3 - .../windows/test.json | 254 ---------- .../windows/test.yaml | 3 - .../others/test.yaml | 3 - .../{others => }/prj.gpr | 0 .../{others => }/test.json | 0 .../invalid_file_name_support/test.yaml | 2 + .../invalid_file_name_support/windows/prj.gpr | 4 - .../windows/test.json | 468 ------------------ .../windows/test.yaml | 3 - 14 files changed, 3 insertions(+), 741 deletions(-) delete mode 100644 testsuite/gpr_lsp/import_using_space_string/others/test.yaml rename testsuite/gpr_lsp/import_using_space_string/{others => }/prj.gpr (100%) rename testsuite/gpr_lsp/import_using_space_string/{others => }/test.json (100%) create mode 100644 testsuite/gpr_lsp/import_using_space_string/test.yaml delete mode 100644 testsuite/gpr_lsp/import_using_space_string/windows/prj.gpr delete mode 100644 testsuite/gpr_lsp/import_using_space_string/windows/test.json delete mode 100644 testsuite/gpr_lsp/import_using_space_string/windows/test.yaml delete mode 100644 testsuite/gpr_lsp/invalid_file_name_support/others/test.yaml rename testsuite/gpr_lsp/invalid_file_name_support/{others => }/prj.gpr (100%) rename testsuite/gpr_lsp/invalid_file_name_support/{others => }/test.json (100%) create mode 100644 testsuite/gpr_lsp/invalid_file_name_support/test.yaml delete mode 100644 testsuite/gpr_lsp/invalid_file_name_support/windows/prj.gpr delete mode 100644 testsuite/gpr_lsp/invalid_file_name_support/windows/test.json delete mode 100644 testsuite/gpr_lsp/invalid_file_name_support/windows/test.yaml diff --git a/testsuite/gpr_lsp/import_using_space_string/others/test.yaml b/testsuite/gpr_lsp/import_using_space_string/others/test.yaml deleted file mode 100644 index 56ea3d85b..000000000 --- a/testsuite/gpr_lsp/import_using_space_string/others/test.yaml +++ /dev/null @@ -1,3 +0,0 @@ -title: 'check with " "; support' -skip: - - ['SKIP', 'env.build.os.name in ("windows")'] \ No newline at end of file diff --git a/testsuite/gpr_lsp/import_using_space_string/others/prj.gpr b/testsuite/gpr_lsp/import_using_space_string/prj.gpr similarity index 100% rename from testsuite/gpr_lsp/import_using_space_string/others/prj.gpr rename to testsuite/gpr_lsp/import_using_space_string/prj.gpr diff --git a/testsuite/gpr_lsp/import_using_space_string/others/test.json b/testsuite/gpr_lsp/import_using_space_string/test.json similarity index 100% rename from testsuite/gpr_lsp/import_using_space_string/others/test.json rename to testsuite/gpr_lsp/import_using_space_string/test.json diff --git a/testsuite/gpr_lsp/import_using_space_string/test.yaml b/testsuite/gpr_lsp/import_using_space_string/test.yaml new file mode 100644 index 000000000..3950b4dd5 --- /dev/null +++ b/testsuite/gpr_lsp/import_using_space_string/test.yaml @@ -0,0 +1 @@ +title: 'check with " "; support' diff --git a/testsuite/gpr_lsp/import_using_space_string/windows/prj.gpr b/testsuite/gpr_lsp/import_using_space_string/windows/prj.gpr deleted file mode 100644 index 4588a6fc0..000000000 --- a/testsuite/gpr_lsp/import_using_space_string/windows/prj.gpr +++ /dev/null @@ -1,3 +0,0 @@ -with " "; -project Prj is -end Prj; \ No newline at end of file diff --git a/testsuite/gpr_lsp/import_using_space_string/windows/test.json b/testsuite/gpr_lsp/import_using_space_string/windows/test.json deleted file mode 100644 index 9198c98e9..000000000 --- a/testsuite/gpr_lsp/import_using_space_string/windows/test.json +++ /dev/null @@ -1,254 +0,0 @@ -[ - { - "comment": [ - "check with \" \"; support" - ] - }, - { - "start": { - "cmd": [ - "${ALS}", - "--language-gpr" - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "init", - "method": "initialize", - "params": { - "processId": 441587, - "rootUri": "$URI{.}", - "capabilities": { - "workspace": { - "applyEdit": true, - "workspaceEdit": {}, - "didChangeConfiguration": {}, - "didChangeWatchedFiles": {}, - "executeCommand": {} - }, - "textDocument": { - "synchronization": {}, - "completion": { - "dynamicRegistration": true, - "completionItem": { - "snippetSupport": true, - "documentationFormat": [ - "plaintext", - "markdown" - ] - } - }, - "hover": {}, - "definition": {}, - "documentSymbol": { - "hierarchicalDocumentSymbolSupport": true - } - } - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "init", - "result": { - "capabilities": { - "textDocumentSync": { - "openClose": true, - "change": 1 - }, - "completionProvider": { - "triggerCharacters": [ - " " - ], - "resolveProvider": true - }, - "hoverProvider": true, - "definitionProvider": true, - "documentSymbolProvider": {} - } - } - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "initialized" - }, - "wait": [] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "textDocument/didOpen", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}", - "languageId": "gpr", - "version": 1, - "text": "with \" \";\nproject Prj is\nend Prj;" - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "method": "textDocument/publishDiagnostics", - "params": { - "uri": "$URI{prj.gpr}", - "diagnostics": [ - { - "range": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 5 - } - }, - "severity": 1, - "message": "imported project file \" .gpr\" not found" - } - ] - } - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/documentSymbol_prj_1", - "method": "textDocument/documentSymbol", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/documentSymbol_prj_1", - "result": [ - { - "name": "with clauses", - "kind": 3, - "range": { - "start": { - "line": 0, - "character": 0 - }, - "end": { - "line": 0, - "character": 0 - } - }, - "selectionRange": { - "start": { - "line": 0, - "character": 0 - }, - "end": { - "line": 0, - "character": 0 - } - }, - "children": [ - { - "name": " ", - "kind": 3, - "range": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 8 - } - }, - "selectionRange": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 8 - } - } - } - ] - }, - { - "name": "Prj", - "kind": 2, - "range": { - "start": { - "line": 1, - "character": 0 - }, - "end": { - "line": 1, - "character": 7 - } - }, - "selectionRange": { - "start": { - "line": 1, - "character": 0 - }, - "end": { - "line": 1, - "character": 7 - } - } - } - ] - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "shutdown", - "method": "shutdown", - "params": null - }, - "wait": [ - { - "id": "shutdown", - "result": null - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "exit" - }, - "wait": [] - } - }, - { - "stop": { - "exit_code": 0 - } - } -] \ No newline at end of file diff --git a/testsuite/gpr_lsp/import_using_space_string/windows/test.yaml b/testsuite/gpr_lsp/import_using_space_string/windows/test.yaml deleted file mode 100644 index 042f35bfc..000000000 --- a/testsuite/gpr_lsp/import_using_space_string/windows/test.yaml +++ /dev/null @@ -1,3 +0,0 @@ -title: 'check with " "; support' -skip: - - ['SKIP', 'env.build.os.name not in ("windows")'] diff --git a/testsuite/gpr_lsp/invalid_file_name_support/others/test.yaml b/testsuite/gpr_lsp/invalid_file_name_support/others/test.yaml deleted file mode 100644 index e0d2d5dc0..000000000 --- a/testsuite/gpr_lsp/invalid_file_name_support/others/test.yaml +++ /dev/null @@ -1,3 +0,0 @@ -title: 'check invalid filename handling' -skip: - - ['SKIP', 'env.build.os.name in ("windows")'] diff --git a/testsuite/gpr_lsp/invalid_file_name_support/others/prj.gpr b/testsuite/gpr_lsp/invalid_file_name_support/prj.gpr similarity index 100% rename from testsuite/gpr_lsp/invalid_file_name_support/others/prj.gpr rename to testsuite/gpr_lsp/invalid_file_name_support/prj.gpr diff --git a/testsuite/gpr_lsp/invalid_file_name_support/others/test.json b/testsuite/gpr_lsp/invalid_file_name_support/test.json similarity index 100% rename from testsuite/gpr_lsp/invalid_file_name_support/others/test.json rename to testsuite/gpr_lsp/invalid_file_name_support/test.json diff --git a/testsuite/gpr_lsp/invalid_file_name_support/test.yaml b/testsuite/gpr_lsp/invalid_file_name_support/test.yaml new file mode 100644 index 000000000..7fbe73d0e --- /dev/null +++ b/testsuite/gpr_lsp/invalid_file_name_support/test.yaml @@ -0,0 +1,2 @@ +title: 'check invalid filename handling' + diff --git a/testsuite/gpr_lsp/invalid_file_name_support/windows/prj.gpr b/testsuite/gpr_lsp/invalid_file_name_support/windows/prj.gpr deleted file mode 100644 index f677aa6f2..000000000 --- a/testsuite/gpr_lsp/invalid_file_name_support/windows/prj.gpr +++ /dev/null @@ -1,4 +0,0 @@ -with " "; -aggregate project prj extends " " is -for Project_Files use (" "); -end prj; diff --git a/testsuite/gpr_lsp/invalid_file_name_support/windows/test.json b/testsuite/gpr_lsp/invalid_file_name_support/windows/test.json deleted file mode 100644 index 2bd7d7157..000000000 --- a/testsuite/gpr_lsp/invalid_file_name_support/windows/test.json +++ /dev/null @@ -1,468 +0,0 @@ -[ - { - "comment": [ - "test invalid filename support" - ] - }, - { - "start": { - "cmd": [ - "${ALS}", - "--language-gpr" - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "init", - "method": "initialize", - "params": { - "processId": 441587, - "rootUri": "$URI{.}", - "capabilities": { - "workspace": { - "applyEdit": true, - "workspaceEdit": {}, - "didChangeConfiguration": {}, - "didChangeWatchedFiles": {}, - "executeCommand": {} - }, - "textDocument": { - "synchronization": {}, - "completion": { - "dynamicRegistration": true, - "completionItem": { - "snippetSupport": true, - "documentationFormat": [ - "plaintext", - "markdown" - ] - } - }, - "hover": {}, - "definition": {}, - "documentSymbol": { - "hierarchicalDocumentSymbolSupport": true - } - } - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "init", - "result": { - "capabilities": { - "textDocumentSync": { - "openClose": true, - "change": 1 - }, - "completionProvider": { - "triggerCharacters": [ - " " - ], - "resolveProvider": true - }, - "hoverProvider": true, - "definitionProvider": true, - "documentSymbolProvider": {} - } - } - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "initialized" - }, - "wait": [] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "textDocument/didOpen", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}", - "languageId": "gpr", - "version": 1, - "text": "with \" \";\naggregate project prj extends \" \" is\nfor Project_Files use (\" \");\nend prj;\n" - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "method": "textDocument/publishDiagnostics", - "params": { - "uri": "$URI{prj.gpr}", - "diagnostics": [ - { - "range": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 5 - } - }, - "severity": 1, - "source": "project", - "message": "imported project file \" .gpr\" not found" - }, - { - "range": { - "start": { - "line": 1, - "character": 22 - }, - "end": { - "line": 1, - "character": 22 - } - }, - "severity": 1, - "source": "project", - "message": "extended project file \" .gpr\" not found" - } - ] - } - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/documentSymbol_prj_1", - "method": "textDocument/documentSymbol", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/documentSymbol_prj_1", - "result": [ - { - "name": "with clauses", - "kind": 3, - "range": { - "start": { - "line": 0, - "character": 0 - }, - "end": { - "line": 0, - "character": 0 - } - }, - "selectionRange": { - "start": { - "line": 0, - "character": 0 - }, - "end": { - "line": 0, - "character": 0 - } - }, - "children": [ - { - "name": " ", - "kind": 3, - "range": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 9 - } - }, - "selectionRange": { - "start": { - "line": 0, - "character": 5 - }, - "end": { - "line": 0, - "character": 9 - } - } - } - ] - }, - { - "name": "prj", - "kind": 2, - "range": { - "start": { - "line": 1, - "character": 10 - }, - "end": { - "line": 1, - "character": 17 - } - }, - "selectionRange": { - "start": { - "line": 1, - "character": 10 - }, - "end": { - "line": 1, - "character": 17 - } - }, - "children": [ - { - "name": "Project_Files", - "kind": 7, - "range": { - "start": { - "line": 2, - "character": 4 - }, - "end": { - "line": 2, - "character": 17 - } - }, - "selectionRange": { - "start": { - "line": 2, - "character": 4 - }, - "end": { - "line": 2, - "character": 17 - } - } - } - ] - } - ] - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_0_7", - "method": "textDocument/hover", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - }, - "position": { - "line": 0, - "character": 7 - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_0_7", - "result": null - } - ] - } - }, - { - "send": { - "request": { - "params": { - "position": { - "line": 0, - "character": 7 - }, - "textDocument": { - "uri": "$URI{prj.gpr}" - } - }, - "jsonrpc": "2.0", - "id": "definition1", - "method": "textDocument/definition" - }, - "wait": [ - { - "id": "definition1", - "result": [] - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_1_32", - "method": "textDocument/hover", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - }, - "position": { - "line": 1, - "character": 32 - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_1_32", - "result": null - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/definition_prj_1_32", - "method": "textDocument/definition", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - }, - "position": { - "line": 1, - "character": 32 - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/definition_prj_1_32", - "result": [] - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_2_25", - "method": "textDocument/hover", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - }, - "position": { - "line": 2, - "character": 25 - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/hover_prj_2_25", - "result": null - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "textDocument/definition_prj_2_25", - "method": "textDocument/definition", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - }, - "position": { - "line": 2, - "character": 25 - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "id": "textDocument/definition_prj_2_25", - "result": [] - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "textDocument/didClose", - "params": { - "textDocument": { - "uri": "$URI{prj.gpr}" - } - } - }, - "wait": [ - { - "jsonrpc": "2.0", - "method": "textDocument/publishDiagnostics", - "params": { - "uri": "$URI{prj.gpr}", - "diagnostics": [] - } - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "id": "shutdown", - "method": "shutdown", - "params": null - }, - "wait": [ - { - "id": "shutdown", - "result": null - } - ] - } - }, - { - "send": { - "request": { - "jsonrpc": "2.0", - "method": "exit" - }, - "wait": [] - } - }, - { - "stop": { - "exit_code": 0 - } - } -] \ No newline at end of file diff --git a/testsuite/gpr_lsp/invalid_file_name_support/windows/test.yaml b/testsuite/gpr_lsp/invalid_file_name_support/windows/test.yaml deleted file mode 100644 index ec17d5d21..000000000 --- a/testsuite/gpr_lsp/invalid_file_name_support/windows/test.yaml +++ /dev/null @@ -1,3 +0,0 @@ -title: 'check invalid filename handling' -skip: - - ['SKIP', 'env.build.os.name not in ("windows")']