summaryrefslogtreecommitdiff
path: root/test/test_standard_handler.vader
blob: 1d1b71c4f5c1df6f9e0ae48c61326daa67d0d818 (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
39
40
41
42
43
44
Execute(The standard handler should parse lines correctly):
  runtime ale_linters/javascript/standard.vim

  AssertEqual
  \ [
  \   {
  \     'bufnr': 347,
  \     'lnum': 47,
  \     'vcol': 0,
  \     'col': 14,
  \     'text': 'Expected indentation of 2 spaces but found 4.',
  \     'type': 'E',
  \     'nr': -1,
  \   },
  \   {
  \     'bufnr': 347,
  \     'lnum': 56,
  \     'vcol': 0,
  \     'col': 41,
  \     'text': 'Strings must use singlequote.',
  \     'type': 'E',
  \     'nr': -1,
  \   },
  \   {
  \     'bufnr': 347,
  \     'lnum': 13,
  \     'vcol': 0,
  \     'col': 3,
  \     'text': 'Parsing error: Unexpected token',
  \     'type': 'E',
  \     'nr': -1,
  \   },
  \ ],
  \ ale_linters#javascript#standard#Handle(347, [
  \   'This line should be ignored completely',
  \   '/path/to/some-filename.js:47:14: Expected indentation of 2 spaces but found 4.',
  \   '/path/to/some-filename.js:56:41: Strings must use singlequote.',
  \   'This line should be ignored completely',
  \   '/path/to/some-filename.js:13:3: Parsing error: Unexpected token',
  \ ])

After:
  call ale#linter#Reset()