From 0843efc7a5010cd1aa0875a0254b466db9f7fc4a Mon Sep 17 00:00:00 2001 From: andys8 Date: Fri, 21 Jun 2019 20:07:23 +0200 Subject: Update elm-ls * elm_lsp is now elm_ls * The binary published by @elm-tooling is elm-language-server Updates tests, docs and adds more options to the plugin. --- .../test_elm_ls_command_callbacks.vader | 29 ++++++++++++++++++++++ .../test_elm_lsp_command_callbacks.vader | 29 ---------------------- 2 files changed, 29 insertions(+), 29 deletions(-) create mode 100644 test/command_callback/test_elm_ls_command_callbacks.vader delete mode 100644 test/command_callback/test_elm_lsp_command_callbacks.vader (limited to 'test/command_callback') diff --git a/test/command_callback/test_elm_ls_command_callbacks.vader b/test/command_callback/test_elm_ls_command_callbacks.vader new file mode 100644 index 00000000..3e1d5fbf --- /dev/null +++ b/test/command_callback/test_elm_ls_command_callbacks.vader @@ -0,0 +1,29 @@ +Before: + call ale#assert#SetUpLinterTest('elm', 'elm_ls') + +After: + call ale#assert#TearDownLinterTest() + +Execute(The default executable path should be correct): + call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') + + AssertLinter 'elm-language-server', ale#Escape('elm-language-server') . ' --stdio' + +Execute(The project root should be detected correctly): + AssertLSPProject '' + + call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') + + AssertLSPProject ale#path#Simplify(g:dir . '/../elm-test-files/newapp') + +Execute(Should let users configure a global executable and override local paths): + call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') + + let g:ale_elm_ls_executable = '/path/to/custom/elm-language-server' + let g:ale_elm_ls_use_global = 1 + + AssertLinter '/path/to/custom/elm-language-server', + \ ale#Escape('/path/to/custom/elm-language-server') . ' --stdio' + +Execute(The language should be correct): + AssertLSPLanguage 'elm' diff --git a/test/command_callback/test_elm_lsp_command_callbacks.vader b/test/command_callback/test_elm_lsp_command_callbacks.vader deleted file mode 100644 index d06ef134..00000000 --- a/test/command_callback/test_elm_lsp_command_callbacks.vader +++ /dev/null @@ -1,29 +0,0 @@ -Before: - call ale#assert#SetUpLinterTest('elm', 'elm_lsp') - -After: - call ale#assert#TearDownLinterTest() - -Execute(The default executable path should be correct): - call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') - - AssertLinter 'elm-lsp', ale#Escape('elm-lsp') . ' --stdio' - -Execute(The project root should be detected correctly): - AssertLSPProject '' - - call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') - - AssertLSPProject ale#path#Simplify(g:dir . '/../elm-test-files/newapp') - -Execute(Should let users configure a global executable and override local paths): - call ale#test#SetFilename('../elm-test-files/newapp/src/Main.elm') - - let g:ale_elm_lsp_executable = '/path/to/custom/elm-lsp' - let g:ale_elm_lsp_use_global = 1 - - AssertLinter '/path/to/custom/elm-lsp', - \ ale#Escape('/path/to/custom/elm-lsp') . ' --stdio' - -Execute(The language should be correct): - AssertLSPLanguage 'elm' -- cgit v1.2.3