diff options
author | Eric Zhao <21zhaoe@protonmail.com> | 2020-11-21 15:56:38 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-21 20:56:38 +0000 |
commit | 9692c0c64c83bb8f67962cf35e7dc3f1757aa8cc (patch) | |
tree | d672572b9eb885b5807f441cb792c9a57c1dc15a /test | |
parent | 5458a1b29167b1fefde5fb6545e371a9d77ca36e (diff) | |
download | ale-9692c0c64c83bb8f67962cf35e7dc3f1757aa8cc.zip |
Add support for R languageserver (#3370)
Diffstat (limited to 'test')
-rw-r--r-- | test/command_callback/r_paths/.Rprofile | 0 | ||||
-rw-r--r-- | test/command_callback/test_r_languageserver_callbacks.vader | 22 |
2 files changed, 22 insertions, 0 deletions
diff --git a/test/command_callback/r_paths/.Rprofile b/test/command_callback/r_paths/.Rprofile new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/test/command_callback/r_paths/.Rprofile diff --git a/test/command_callback/test_r_languageserver_callbacks.vader b/test/command_callback/test_r_languageserver_callbacks.vader new file mode 100644 index 00000000..7829165c --- /dev/null +++ b/test/command_callback/test_r_languageserver_callbacks.vader @@ -0,0 +1,22 @@ +Before: + call ale#assert#SetUpLinterTest('r', 'languageserver') + +After: + call ale#assert#TearDownLinterTest() + +Execute(The default executable path should be correct): + AssertLinter 'Rscript', 'Rscript --vanilla -e ' . ale#Escape('languageserver::run()') + +Execute(The project root should be detected correctly): + AssertLSPProject '.' + + call ale#test#SetFilename('r_paths/dummy/test.R') + + AssertLSPProject ale#path#Simplify(g:dir . '/r_paths') + +Execute(Should accept configuration settings): + AssertLSPConfig {} + + let b:ale_r_languageserver_options = {'r': {'lsp': {'debug': 'true', 'diagnostics': 'true'}}} + + AssertLSPConfig {'r': {'lsp': {'debug': 'true', 'diagnostics': 'true'}}} |