summaryrefslogtreecommitdiff
path: root/test/linter
diff options
context:
space:
mode:
Diffstat (limited to 'test/linter')
-rw-r--r--test/linter/test_lexical.vader28
1 files changed, 28 insertions, 0 deletions
diff --git a/test/linter/test_lexical.vader b/test/linter/test_lexical.vader
new file mode 100644
index 00000000..a5ca2f9e
--- /dev/null
+++ b/test/linter/test_lexical.vader
@@ -0,0 +1,28 @@
+Before:
+ call ale#assert#SetUpLinterTest('elixir', 'lexical')
+
+After:
+ call ale#assert#TearDownLinterTest()
+
+Execute(should set correct defaults):
+ if has('win32')
+ AssertLinter 'lexical\start_lexical.bat', 'lexical\start_lexical.bat'
+ else
+ AssertLinter 'lexical/start_lexical.sh', 'lexical/start_lexical.sh'
+ endif
+
+Execute(should configure lexical release location):
+ let b:ale_elixir_lexical_release = 'boo'
+
+ if has('win32')
+ AssertLinter 'boo\start_lexical.bat', 'boo\start_lexical.bat'
+ else
+ AssertLinter 'boo/start_lexical.sh', 'boo/start_lexical.sh'
+ endif
+
+Execute(should set correct LSP values):
+ call ale#test#SetFilename('../test-files/elixir/umbrella_project/apps/app1/lib/app.ex')
+
+ AssertLSPLanguage 'elixir'
+ AssertLSPOptions {}
+ AssertLSPProject ale#path#Simplify(g:dir . '/../test-files/elixir/umbrella_project')