diff options
author | w0rp <devw0rp@gmail.com> | 2018-12-18 09:28:55 +0000 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2018-12-18 09:28:55 +0000 |
commit | 9a3be907ea9a3f1e4646fcf3cef43a3572a7eaa2 (patch) | |
tree | 20c55691fff2711907ec2567674e065ff0d26ddd /test/fixers | |
parent | 13060a3492f9417831802c39808d70237b906ae1 (diff) | |
download | ale-9a3be907ea9a3f1e4646fcf3cef43a3572a7eaa2.zip |
Close #2152 - Use ale_javascript_standard_options for fixing files too
Diffstat (limited to 'test/fixers')
-rw-r--r-- | test/fixers/test_standard_fixer_callback.vader | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/fixers/test_standard_fixer_callback.vader b/test/fixers/test_standard_fixer_callback.vader index 38f2d54a..db9f20f6 100644 --- a/test/fixers/test_standard_fixer_callback.vader +++ b/test/fixers/test_standard_fixer_callback.vader @@ -1,6 +1,9 @@ Before: call ale#test#SetDirectory('/testplugin/test/fixers') + unlet! b:ale_javascript_standard_executable + unlet! b:ale_javascript_standard_options + After: call ale#test#RestoreDirectory() @@ -15,3 +18,14 @@ Execute(The executable path should be correct): \ . ' --fix %t', \ }, \ ale#fixers#standard#Fix(bufnr('')) + +Execute(Custom options should be supported): + let b:ale_javascript_standard_use_global = 1 + let b:ale_javascript_standard_options = '--foo-bar' + + AssertEqual + \ { + \ 'read_temporary_file': 1, + \ 'command': ale#Escape('standard') . ' --foo-bar --fix %t', + \ }, + \ ale#fixers#standard#Fix(bufnr('')) |