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