2017-07-18 22:57:33 +00:00
|
|
|
Before:
|
2018-07-15 17:24:53 +00:00
|
|
|
call ale#assert#SetUpLinterTest('dart', 'dartanalyzer')
|
2017-07-18 22:57:33 +00:00
|
|
|
|
|
|
|
After:
|
2018-07-15 17:24:53 +00:00
|
|
|
call ale#assert#TearDownLinterTest()
|
2017-07-18 22:57:33 +00:00
|
|
|
|
|
|
|
Execute(The default command and executable should be correct):
|
2018-07-15 17:24:53 +00:00
|
|
|
AssertLinter 'dartanalyzer', ale#Escape('dartanalyzer') . ' %s'
|
2017-07-18 22:57:33 +00:00
|
|
|
|
|
|
|
Execute(The executable should be configurable):
|
2018-07-15 17:24:53 +00:00
|
|
|
let g:ale_dart_dartanalyzer_executable = 'foobar'
|
2017-07-18 22:57:33 +00:00
|
|
|
|
2018-07-15 17:24:53 +00:00
|
|
|
AssertLinter 'foobar', ale#Escape('foobar') . ' %s'
|
2017-07-18 22:57:33 +00:00
|
|
|
|
|
|
|
Execute(The .packages file should be set if detected):
|
2021-03-20 22:11:22 +00:00
|
|
|
call ale#test#SetFilename('../test-files/dart/foo')
|
2017-07-18 22:57:33 +00:00
|
|
|
|
2018-07-15 17:24:53 +00:00
|
|
|
AssertLinter 'dartanalyzer', ale#Escape('dartanalyzer')
|
2021-03-20 22:11:22 +00:00
|
|
|
\ . ' --packages ' . ale#Escape(ale#path#Simplify(g:dir . '/../test-files/dart/.packages'))
|
2018-07-15 17:24:53 +00:00
|
|
|
\ . ' %s'
|