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_swift_sourcekitlsp_command_callbacks.vader
Dan Loman 864d0861e4 [lsp] Add Swift / SourceKit-LSP support (#2420)
* [linter] Add LSP support for Swift via sourcekit-lsp
2019-04-08 16:25:30 +01:00

21 lines
743 B
Text

Before:
call ale#assert#SetUpLinterTest('swift', 'sourcekitlsp')
After:
call ale#assert#TearDownLinterTest()
Execute(The default executable path should be correct):
call ale#test#SetFilename('../swift-test-files/swift-package-project/src/folder/dummy.swift')
AssertLinter 'sourcekit-lsp', ale#Escape('sourcekit-lsp')
Execute(Should let users configure a global executable and override local paths):
call ale#test#SetFilename('../swift-test-files/swift-package-project/src/folder/dummy.swift')
let g:ale_sourcekit_lsp_executable = '/path/to/custom/sourcekitlsp'
AssertLinter '/path/to/custom/sourcekitlsp',
\ ale#Escape('/path/to/custom/sourcekitlsp')
Execute(The language should be correct):
AssertLSPLanguage 'swift'