2018-02-25 11:39:45 +00:00
|
|
|
Before:
|
2018-09-19 19:33:23 +01:00
|
|
|
Save g:ale_go_go_executable
|
|
|
|
Save g:ale_go_govet_options
|
2018-07-15 18:24:53 +01:00
|
|
|
call ale#assert#SetUpLinterTest('go', 'govet')
|
2018-02-25 11:39:45 +00:00
|
|
|
|
|
|
|
After:
|
2018-09-19 19:33:23 +01:00
|
|
|
Restore
|
2018-07-15 18:24:53 +01:00
|
|
|
call ale#assert#TearDownLinterTest()
|
2018-02-25 11:39:45 +00:00
|
|
|
|
|
|
|
Execute(The default command should be correct):
|
2018-10-23 23:20:27 +09:00
|
|
|
AssertLinter 'go', ale#path#CdString(expand('%:p:h')) . ' go vet .'
|
2018-08-16 11:02:51 +09:00
|
|
|
|
|
|
|
Execute(Extra options should be supported):
|
|
|
|
let g:ale_go_govet_options = '--foo-bar'
|
2018-10-23 23:20:27 +09:00
|
|
|
AssertLinter 'go', ale#path#CdString(expand('%:p:h')) . ' go vet --foo-bar .'
|
2018-09-19 19:33:23 +01:00
|
|
|
|
|
|
|
Execute(The executable should be configurable):
|
|
|
|
let g:ale_go_go_executable = 'foobar'
|
2018-10-23 23:20:27 +09:00
|
|
|
AssertLinter 'foobar', ale#path#CdString(expand('%:p:h')) . ' foobar vet .'
|