Skip to content

Commit e04e5b4

Browse files
committed
Merge branch 'topic/fix_settings' into 'master'
Synchronize seddings documentsion with `package.json` See merge request eng/ide/ada_language_server!1185
2 parents ee716fc + ea90bc4 commit e04e5b4

File tree

6 files changed

+93
-1
lines changed

6 files changed

+93
-1
lines changed

doc/settings.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,3 +210,8 @@ For more information about documentation styles see GNATdoc User's Manual.
210210
```javascript
211211
'documentationStyle': 'gnat'
212212
```
213+
214+
## trace.server
215+
216+
This option controls the tracing of the communication between VSCode and the Ada language server.
217+
The separate setting `gpr.trace.server` controls tracing for GPR language server.

integration/vscode/ada/package.json

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,6 +312,20 @@
312312
"default": "iso-8859-1",
313313
"description": "The character set to use while reading files from disk."
314314
},
315+
"ada.documentationStyle": {
316+
"scope": "resource",
317+
"type": "string",
318+
"enum": [
319+
"gnat",
320+
"leading"
321+
],
322+
"enumDescriptions": [
323+
"Default style, based on GNAT coding standard with some enhancements.",
324+
"Documentation for the entities extracted from the comments before the entity declaration."
325+
],
326+
"default": "gnat",
327+
"description": "Controls primary documentation style of entities."
328+
},
315329
"ada.displayMethodAncestryOnNavigation": {
316330
"scope": "resource",
317331
"type": "string",
@@ -336,6 +350,42 @@
336350
"default": true,
337351
"description": "The emission of diagnostics."
338352
},
353+
"ada.enableIndexing": {
354+
"scope": "resource",
355+
"type": "boolean",
356+
"default": true,
357+
"description": "Controls indexing the source files after loading a project."
358+
},
359+
"ada.foldComments": {
360+
"scope": "resource",
361+
"type": "boolean",
362+
"default": true,
363+
"description": "Controls the inclusion of comments in folding blocks."
364+
},
365+
"ada.followSymlinks": {
366+
"scope": "resource",
367+
"type": "boolean",
368+
"default": true,
369+
"description": "Controls the file names normalization sent by a client."
370+
},
371+
"ada.namedNotationThreshold": {
372+
"scope": "resource",
373+
"type": "integer",
374+
"default": 3,
375+
"description": "Defines the number of parameters/components at which point named notation is used for completion snippets."
376+
},
377+
"ada.relocateBuildTree": {
378+
"scope": "resource",
379+
"type": "string",
380+
"default": "",
381+
"description": "The folder for out-of-tree build."
382+
},
383+
"ada.rootDir": {
384+
"scope": "resource",
385+
"type": "string",
386+
"default": "",
387+
"description": "The root directory for artifacts for proper relocation. Used with relocateBuildTree."
388+
},
339389
"ada.useCompletionSnippets": {
340390
"scope": "resource",
341391
"type": "boolean",

testsuite/drivers/shell.py

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import os.path
2+
3+
from e3.testsuite.result import TestStatus
4+
5+
from drivers import ALSTestDriver
6+
7+
8+
class ShellTestDriver(ALSTestDriver):
9+
"""
10+
Run the test.sh test program.
11+
12+
"""
13+
14+
def run(self, previous_values, slot):
15+
# Check whether the test should be skipped
16+
if self.should_skip():
17+
return False
18+
19+
index = os.path.abspath(os.path.join(self.test_env["test_dir"], "index.txt"))
20+
test_sh = os.path.join(self.env.repo_base, 'testsuite', 'shell', 'test.sh')
21+
p = self.run_and_log([test_sh, self.env.repo_base], cwd=self.env.working_dir)
22+
self.result.out += p.out
23+
24+
self.result.set_status(TestStatus.PASS if p.status == 0 else TestStatus.FAIL)
25+
self.push_result()

testsuite/shell/test.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
jq -r '.contributes.configuration[].properties|keys[]' < $1/integration/vscode/ada/package.json | grep ^ada. > pkg.txt
3+
grep '^## ' $1/doc/settings.md |sed -e 's/.../ada./' | sort > doc.txt
4+
diff -u pkg.txt doc.txt

testsuite/shell/test.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
driver: shell
2+
title: 'settings_docs'
3+
# Test only on Linux, since it depends on `bash`, `jq` and `diff`
4+
skip:
5+
- ['SKIP', 'env.build.os.name != "linux"']

testsuite/testsuite.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,11 @@
66

77
from distutils.spawn import find_executable
88
from e3.testsuite import Testsuite
9+
from e3.testsuite.driver.diff import DiffTestDriver
910

1011
from drivers.basic import JsonTestDriver
1112
from drivers.codecs import CodecsTestDriver
13+
from drivers.shell import ShellTestDriver
1214
from drivers.gnatcov import GNATcov
1315

1416
VALGRIND_OPTIONS = [
@@ -99,7 +101,8 @@ def tear_down(self):
99101
@property
100102
def test_driver_map(self):
101103
return {'ada_lsp': JsonTestDriver,
102-
'codecs': CodecsTestDriver}
104+
'codecs': CodecsTestDriver,
105+
'shell': ShellTestDriver}
103106

104107
@property
105108
def default_driver(self):

0 commit comments

Comments
 (0)