summaryrefslogtreecommitdiff
path: root/test/handler/test_ruby_handler.vader
blob: 824d8c582bcc92b6eaefa80195652b30c458736f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
Before:
  runtime ale_linters/ruby/ruby.vim

After:
  call ale#linter#Reset()

Execute(The ruby handler should parse lines correctly and add the column if it can):
  " Point Error
  " Warning
  " Line Error
  AssertEqual
  \ [
  \   {
  \     'lnum': 6,
  \     'col': 13,
  \     'type': 'E',
  \     'text': 'syntax error, unexpected '';'''
  \   },
  \   {
  \     'lnum': 9,
  \     'col': 0,
  \     'type': 'W',
  \     'text': 'warning: statement not reached'
  \   },
  \   {
  \     'lnum': 12,
  \     'col': 0,
  \     'type': 'E',
  \     'text': 'syntax error, unexpected end-of-input, expecting keyword_end'
  \   }
  \ ],
  \ ale#handlers#ruby#HandleSyntaxErrors(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",
  \ ])