remark-lint without saving to disk

This commit is contained in:
Takashi WADA
2018-07-10 22:06:43 +09:00
committed by WADA Takashi
parent f369aa65a2
commit dbf051e62b
3 changed files with 7 additions and 8 deletions

View File

@@ -7,19 +7,19 @@ After:
Execute(The default command should be correct):
AssertLinter 'remark',
\ ale#Escape('remark') . ' --no-stdout --no-color %s'
\ ale#Escape('remark') . ' --no-stdout --no-color'
Execute(The executable should be configurable):
let b:ale_markdown_remark_lint_executable = 'foobar'
AssertLinter 'foobar',
\ ale#Escape('foobar') . ' --no-stdout --no-color %s'
\ ale#Escape('foobar') . ' --no-stdout --no-color'
Execute(The options should be configurable):
let b:ale_markdown_remark_lint_options = '--something'
AssertLinter 'remark',
\ ale#Escape('remark') . ' --something --no-stdout --no-color %s'
\ ale#Escape('remark') . ' --something --no-stdout --no-color'
Execute(The local executable from .bin should be used if available):
call ale#test#SetFilename('remark_lint_paths/with_bin_path/foo.md')
@@ -27,11 +27,11 @@ Execute(The local executable from .bin should be used if available):
AssertLinter
\ ale#path#Simplify(g:dir . '/remark_lint_paths/with_bin_path/node_modules/.bin/remark'),
\ ale#Escape(ale#path#Simplify(g:dir . '/remark_lint_paths/with_bin_path/node_modules/.bin/remark'))
\ . ' --no-stdout --no-color %s'
\ . ' --no-stdout --no-color'
Execute(The global executable should be uesd if the option is set):
let b:ale_markdown_remark_lint_use_global = 1
call ale#test#SetFilename('remark_lint_paths/with_bin_path/foo.md')
AssertLinter 'remark', ale#Escape('remark')
\ . ' --no-stdout --no-color %s'
\ . ' --no-stdout --no-color'