diff options
author | Brandon Roehl <SkyGuy913@gmail.com> | 2017-04-08 05:24:20 -0500 |
---|---|---|
committer | w0rp <w0rp@users.noreply.github.com> | 2017-04-08 11:24:20 +0100 |
commit | 4e40e8cb608fef9b088e6712d83f4fc3dccd5e77 (patch) | |
tree | 270316220de5e547f2fe7f3f565ffb2f3f2b2a5c /test | |
parent | cc8eb0586043f1fcec73595c8a43d895a4753a05 (diff) | |
download | ale-4e40e8cb608fef9b088e6712d83f4fc3dccd5e77.zip |
Add Ruby MRI linter (#453)
* Added ruby mri linter
* Added to the list of supported linters
* Async and now with 4 spaces
* Vader tests for ruby
* Match style choices
* Vader test for the Ruby handler now works and passes
Diffstat (limited to 'test')
-rw-r--r-- | test/handler/test_ruby_handler.vader | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/test/handler/test_ruby_handler.vader b/test/handler/test_ruby_handler.vader new file mode 100644 index 00000000..573711f7 --- /dev/null +++ b/test/handler/test_ruby_handler.vader @@ -0,0 +1,39 @@ +Execute(The ruby handler should parse lines correctly and add the column if it can): + runtime ale_linters/ruby/ruby.vim + " Point Error + " Warning + " Line Error + AssertEqual + \ [ + \ { + \ 'lnum': 6, + \ 'bufnr': 255, + \ 'col': 13, + \ 'type': 'E', + \ 'text': 'syntax error, unexpected '';''' + \ }, + \ { + \ 'lnum': 9, + \ 'bufnr': 255, + \ 'col': 0, + \ 'type': 'W', + \ 'text': 'warning: statement not reached' + \ }, + \ { + \ 'lnum': 12, + \ 'bufnr': 255, + \ 'col': 0, + \ 'type': 'E', + \ 'text': 'syntax error, unexpected end-of-input, expecting keyword_end' + \ } + \ ], + \ ale_linters#ruby#ruby#Handle(255, [ + \ "test.rb:6: syntax error, unexpected ';'", + \ " t = ;", + \ " ^", + \ "test.rb:9: warning: statement not reached", + \ "test.rb:12: syntax error, unexpected end-of-input, expecting keyword_end", + \ ]) + +After: + call ale#linter#Reset() |