diff options
author | Kevin Kays <kkays@raybeam.com> | 2017-07-13 18:41:01 -0400 |
---|---|---|
committer | w0rp <w0rp@users.noreply.github.com> | 2017-07-13 23:41:01 +0100 |
commit | 4c50aec79c158a61de27f273e1d338fb1d817021 (patch) | |
tree | d37c582252ac0655e732545f85930b97567a1eb5 /test/command_callback | |
parent | 4c6c5bf84fa31ab18ff83122c12b7e8edb18bd1e (diff) | |
download | ale-4c50aec79c158a61de27f273e1d338fb1d817021.zip |
Add scalastyle linter (#766)
* Add support for scalastyle
* Add scalastyle docs
* scalastyle support for column numbers
* off by one column
* Add tests for scalastyle command and handler
* update readme for scalastyle
* allow full scalastyle options instead of just config file
* fix indentation
* allow scalastyle config file in parent directories by a couple names.
* check for missing match args with empty
* remove echo
* use a for loop
Diffstat (limited to 'test/command_callback')
-rw-r--r-- | test/command_callback/test_scalastyle_command_callback.vader | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/test/command_callback/test_scalastyle_command_callback.vader b/test/command_callback/test_scalastyle_command_callback.vader new file mode 100644 index 00000000..f051b025 --- /dev/null +++ b/test/command_callback/test_scalastyle_command_callback.vader @@ -0,0 +1,27 @@ +Before: + runtime ale_linters/scala/scalastyle.vim + +After: + call ale#linter#Reset() + let g:ale_scala_scalastyle_options = '' + let g:ale_scalastyle_conf_loc = '' + +Execute(Should return the correct default command): + AssertEqual + \ 'scalastyle %t', + \ ale_linters#scala#scalastyle#GetCommand(bufnr('')) + +Execute(Should allow using a custom config file): + let g:ale_scalastyle_config_loc = '/dooper/config.xml' + + AssertEqual + \ 'scalastyle --config ''/dooper/config.xml'' %t', + \ ale_linters#scala#scalastyle#GetCommand(bufnr('')) + +Execute(Should allow using custom options): + let g:ale_scala_scalastyle_options = '--warnings false --quiet true' + + AssertEqual + \ 'scalastyle --config ''/dooper/config.xml'' --warnings false --quiet true %t', + \ ale_linters#scala#scalastyle#GetCommand(bufnr('')) + |