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_ruby_solargraph.vader

40 lines
1.6 KiB
Text
Raw Normal View History

2018-08-24 04:02:51 +00:00
" Author: Horacio Sanson <https://github.com/hsanson>
" Description: Tests for solargraph lsp linter.
Before:
call ale#assert#SetUpLinterTest('ruby', 'solargraph')
After:
call ale#assert#TearDownLinterTest()
2018-09-18 14:33:22 +00:00
Execute(command callback should return default string):
AssertLinter 'solargraph', ale#Escape('solargraph') . ' stdio'
Execute(command callback executable can be overridden):
let g:ale_ruby_solargraph_executable = 'foobar'
AssertLinter 'foobar', ale#Escape('foobar') . ' stdio'
2018-08-24 04:02:51 +00:00
Execute(should set solargraph for rails app):
call ale#test#SetFilename('../ruby_fixtures/valid_rails_app/app/models/thing.rb')
AssertLSPLanguage 'ruby'
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_rails_app')
Execute(should set solargraph for ruby app1):
call ale#test#SetFilename('../ruby_fixtures/valid_ruby_app1/lib/file.rb')
AssertLSPLanguage 'ruby'
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_ruby_app1')
Execute(should set solargraph for ruby app2):
call ale#test#SetFilename('../ruby_fixtures/valid_ruby_app2/lib/file.rb')
AssertLSPLanguage 'ruby'
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_ruby_app2')
Execute(should set solargraph for ruby app3):
call ale#test#SetFilename('../ruby_fixtures/valid_ruby_app3/lib/file.rb')
AssertLSPLanguage 'ruby'
AssertLSPOptions {}
AssertLSPProject ale#path#Simplify(g:dir . 'command_callback/../ruby_fixtures/valid_ruby_app3')