mirror of
https://github.com/dense-analysis/ale.git
synced 2026-02-21 17:18:38 +08:00
#3633 - Move linter tests into test/linter
This commit is contained in:
25
test/linter/test_gawk.vader
Normal file
25
test/linter/test_gawk.vader
Normal file
@@ -0,0 +1,25 @@
|
||||
Before:
|
||||
call ale#assert#SetUpLinterTest('awk', 'gawk')
|
||||
|
||||
After:
|
||||
call ale#assert#TearDownLinterTest()
|
||||
|
||||
Execute(The default command should be correct):
|
||||
AssertLinter 'gawk',
|
||||
\ ale#Escape('gawk') . ' --source ' . ale#Escape('BEGIN { exit } END { exit 1 }')
|
||||
\ . ' -f %t --lint /dev/null'
|
||||
|
||||
Execute(The executable should be configurable):
|
||||
let b:ale_awk_gawk_executable = '/other/gawk'
|
||||
|
||||
AssertLinter '/other/gawk',
|
||||
\ ale#Escape('/other/gawk') . ' --source ' . ale#Escape('BEGIN { exit } END { exit 1 }')
|
||||
\ . ' -f %t --lint /dev/null'
|
||||
|
||||
Execute(The options should be configurable):
|
||||
let b:ale_awk_gawk_executable = 'gawk'
|
||||
let b:ale_awk_gawk_options = '--something'
|
||||
|
||||
AssertLinter 'gawk',
|
||||
\ ale#Escape('gawk') . ' --source ' . ale#Escape('BEGIN { exit } END { exit 1 }')
|
||||
\ . ' --something -f %t --lint /dev/null'
|
||||
Reference in New Issue
Block a user