Merge pull request #1254 from bkhl/master
Don't use temporary file for rustfmt fixer
This commit is contained in:
commit
e98a3899da
2 changed files with 3 additions and 9 deletions
|
@ -10,8 +10,6 @@ function! ale#fixers#rustfmt#Fix(buffer) abort
|
|||
|
||||
return {
|
||||
\ 'command': ale#Escape(l:executable)
|
||||
\ . (empty(l:options) ? '' : ' ' . l:options)
|
||||
\ . ' %t',
|
||||
\ 'read_temporary_file': 1,
|
||||
\ . (empty(l:options) ? '' : ' ' . l:options),
|
||||
\}
|
||||
endfunction
|
||||
|
|
|
@ -18,9 +18,7 @@ Execute(The rustfmt callback should return the correct default values):
|
|||
|
||||
AssertEqual
|
||||
\ {
|
||||
\ 'read_temporary_file': 1,
|
||||
\ 'command': ale#Escape('xxxinvalid')
|
||||
\ . ' %t',
|
||||
\ 'command': ale#Escape('xxxinvalid'),
|
||||
\ },
|
||||
\ ale#fixers#rustfmt#Fix(bufnr(''))
|
||||
|
||||
|
@ -30,9 +28,7 @@ Execute(The rustfmt callback should include custom rustfmt options):
|
|||
|
||||
AssertEqual
|
||||
\ {
|
||||
\ 'read_temporary_file': 1,
|
||||
\ 'command': ale#Escape('xxxinvalid')
|
||||
\ . ' ' . g:ale_rust_rustfmt_options
|
||||
\ . ' %t',
|
||||
\ . ' ' . g:ale_rust_rustfmt_options,
|
||||
\ },
|
||||
\ ale#fixers#rustfmt#Fix(bufnr(''))
|
||||
|
|
Reference in a new issue