diff options
Diffstat (limited to 'test/command_callback/test_jscs_command_callback.vader')
-rw-r--r-- | test/command_callback/test_jscs_command_callback.vader | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/test/command_callback/test_jscs_command_callback.vader b/test/command_callback/test_jscs_command_callback.vader new file mode 100644 index 00000000..8245337e --- /dev/null +++ b/test/command_callback/test_jscs_command_callback.vader @@ -0,0 +1,25 @@ +Before: + runtime ale_linters/javascript/jscs.vim + +After: + call ale#linter#Reset() + let g:ale_javascript_jscs_executable = 'jscs' + +Execute(Should return the correct default values): + AssertEqual + \ 'jscs', + \ ale_linters#javascript#jscs#GetExecutable(bufnr('')) + AssertEqual + \ '''jscs'' --reporter inline --no-colors -', + \ ale_linters#javascript#jscs#GetCommand(bufnr('')) + + +Execute(Should allow using a custom executable): + let g:ale_javascript_jscs_executable = 'foobar' + + AssertEqual + \ 'foobar', + \ ale_linters#javascript#jscs#GetExecutable(bufnr('')) + AssertEqual + \ '''foobar'' --reporter inline --no-colors -', + \ ale_linters#javascript#jscs#GetCommand(bufnr('')) |