summaryrefslogtreecommitdiff
path: root/test/handler/test_nix_handler.vader
blob: 188d3fa98117b3075059e3f2ae8f9ea6063abeb7 (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
Execute(The nix handler should parse nix-instantiate error messages correctly):
  runtime ale_linters/nix/nix.vim

  AssertEqual
  \ [
  \   {
  \     'bufnr': 47,
  \     'lnum': 23,
  \     'col': 14,
  \     'text': 'error: syntax error, unexpected IN',
  \     'type': 'E',
  \   },
  \   {
  \     'bufnr': 47,
  \     'lnum': 3,
  \     'col': 12,
  \     'text': 'error: syntax error, unexpected ''='', expecting '';''',
  \     'type': 'E',
  \   },
  \
  \ ],
  \ ale_linters#nix#nix#Handle(47, [
  \   'This line should be ignored',
  \   'error: syntax error, unexpected IN, at /path/to/filename.nix:23:14',
  \   'error: syntax error, unexpected ''='', expecting '';'', at /path/to/filename.nix:3:12',
  \ ])