Merge pull request #1111 from elebow/perlcritic-only-warnings
Perlcritic: All issues are warnings
This commit is contained in:
commit
3111c6c1ca
@ -61,6 +61,7 @@ function! ale_linters#perl#perlcritic#Handle(buffer, lines) abort
|
|||||||
\ 'lnum': l:match[1],
|
\ 'lnum': l:match[1],
|
||||||
\ 'col': l:match[2],
|
\ 'col': l:match[2],
|
||||||
\ 'text': l:match[3],
|
\ 'text': l:match[3],
|
||||||
|
\ 'type': 'W'
|
||||||
\})
|
\})
|
||||||
endfor
|
endfor
|
||||||
|
|
||||||
|
20
test/handler/test_perlcritic_handler.vader
Normal file
20
test/handler/test_perlcritic_handler.vader
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
Before:
|
||||||
|
runtime ale_linters/perl/perlcritic.vim
|
||||||
|
|
||||||
|
After:
|
||||||
|
call ale#linter#Reset()
|
||||||
|
|
||||||
|
Execute(The Perl::Critic handler should create all issues as warnings):
|
||||||
|
AssertEqual
|
||||||
|
\ [
|
||||||
|
\ {
|
||||||
|
\ 'lnum': '21',
|
||||||
|
\ 'col': '17',
|
||||||
|
\ 'text': 'Regular expression without "/m" flag',
|
||||||
|
\ 'type': 'W',
|
||||||
|
\ }
|
||||||
|
\ ],
|
||||||
|
\ ale_linters#perl#perlcritic#Handle(99, [
|
||||||
|
\ '21:17 Regular expression without "/m" flag'
|
||||||
|
\ ])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user