This repository has been archived on 2024-07-19. You can view files and clone it, but cannot push or open issues or pull requests.
ale/test/command_callback/test_javalsp_command_callback.vader

32 lines
1.1 KiB
Text
Raw Normal View History

Before:
call ale#assert#SetUpLinterTest('java', 'javalsp')
After:
call ale#assert#TearDownLinterTest()
Execute(The javalsp callback should return the correct default value):
AssertLinter '', ale#Escape('')
Execute(The javalsp java executable should be configurable):
let b:ale_java_javalsp_executable = '/bin/foobar'
AssertLinter '/bin/foobar', ale#Escape('/bin/foobar')
Execute(The javalsp callback should return backward compatible value):
let b:ale_java_javalsp_executable = '/bin/java'
let cmd = [
\ ale#Escape('/bin/java'),
\ '--add-exports jdk.compiler/com.sun.tools.javac.api=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.code=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.comp=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.main=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.tree=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.model=javacs',
\ '--add-exports jdk.compiler/com.sun.tools.javac.util=javacs',
\ '--add-opens jdk.compiler/com.sun.tools.javac.api=javacs',
\ '-m javacs/org.javacs.Main',
\]
AssertLinter '/bin/java', join(cmd, ' ')